Open kaborso opened 3 years ago
hi, this would be really usefull if some implements. Thanks
I have created this PR:
https://github.com/convictional/trigger-workflow-and-wait/pull/85
It's solving the problem of the "conclusion" variable in the $GITHUB_OUTPUT.
You can try my first release, it's a fork of this repo, like this:
steps:
- name: 'Run test'
id: 'run-test'
uses: Enrico-Infrinity/trigger-workflow-and-wait@v1.0
with:
owner: remoteOwner
repo: remoteRepo
github_token: ${{ secrets.CICD_REPO_TOKEN }}
workflow_file_name: main.yml
ref: main
wait_interval: 10
client_payload: '{}'
propagate_failure: false
trigger_workflow: true
wait_workflow: true
- name: 'Set result'
run: |
echo ${{ steps.run-test.outputs.conclusion }}
If someone here can do a review of my PR, maybe we can get something official and stable :)
could we get this PR merged @Enrico-Infrinity ??
The
propagate_failure
option does not account for other statuses returned by the downstream job, so the action only returnsfailure
orsuccess
. Theconclusion
environment variable holds the actual status reported by the downstream job. I propose exporting it as an output from the action for use in subsequent steps that may need to respond to whether the job timed out, was skipped, was cancelled, and so on.