File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 7373 env :
7474 GH_TOKEN : ${{ secrets.GITHUB_TOKEN }}
7575 run : |
76- toys ci report-failures -v
76+ toys ci report-failures --github-action-id=${{ github.run_id }} - v
Original file line number Diff line number Diff line change @@ -370,6 +370,9 @@ def generate_failures_json
370370
371371tool "report-failures" do
372372 flag :report_path , "--report-path=PATH" , default : FAILURES_REPORT_PATH
373+ flag :github_action_id , "--github-action-id=ACTION_ID" do |f |
374+ f . desc "Github Action ID under which the CI is running. Optional."
375+ end
373376
374377 include :exec , e : true
375378 include :terminal
@@ -433,6 +436,11 @@ def encode_str str
433436
434437 def create_body dir , tasks
435438 now = Time . now . utc . strftime "%Y-%m-%d %H:%M:%S"
436- "At #{ now } UTC, detected failures in #{ dir } for: #{ tasks . join ', ' } "
439+ messages = [ ]
440+ messages << "At #{ now } UTC, detected failures in #{ dir } for: #{ tasks . join ', ' } ."
441+ unless github_action_id . nil?
442+ messages << "The CI logs can be found [here](https://github.com/googleapis/google-cloud-ruby/actions/runs/#{ github_action_id } )"
443+ end
444+ messages . join "\n \n "
437445 end
438446end
You can’t perform that action at this time.
0 commit comments