Triggered via 01-run-on-push#32(7573667407) for a push event #35
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: 02-run-after-another | |
run-name: Triggered via ${{ github.event.workflow_run.name }}#${{ github.event.workflow_run.run_number }}(${{ github.event.workflow_run.id }}) for a ${{ github.event.workflow_run.event }} event | |
on: | |
workflow_run: | |
workflows: [01-run-on-push, 03-run-on-pull-request] | |
types: [completed] | |
jobs: | |
if-pr: | |
runs-on: ubuntu-latest | |
if: ${{ (github.event.workflow_run.event == 'pull_request') && (github.event.workflow_run.conclusion == 'success') }} | |
steps: | |
- run: echo 'The triggering workflow has passed and was triggered via a pull_request' | |
if-push: | |
runs-on: ubuntu-latest | |
if: ${{ (github.event.workflow_run.event == 'push') && (github.event.workflow_run.conclusion == 'success') }} | |
steps: | |
- run: echo 'The triggering workflow has passed and was triggered via a push' | |
run-after-another: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Dump GitHub context | |
env: | |
GITHUB_CONTEXT: ${{ toJson(github) }} | |
run: | | |
echo "$GITHUB_CONTEXT" |