Autodetect Pull requests from 'push' events
based on the work from https://github.com/barecheck/code-coverage-action/pull/293, there is a new parameter that was added to pass params as 'input'.
Ideally, we would like to include the logic and auto-detect Pull requests as part of the action to avoid writing complex docs how these params can be used.
barecheck/code-coverage-action Action is of type JS, which means we can't simply abstract away another Action for grabbing the PR number in a composite Action type.
The Action I have used for determining the pull request number is this
- https://github.com/jwalton/gh-find-current-pr
It is also of type JS and has an MIT license. At a glance, it looks trivial to take the logic used by this Action and include it as part of barecheck/code-coverage-action.
Hi @garyburgmann thanks for looking.
I was thinking the same that we could just add the logic as part of the barecheck/code-coverage-action.
It shouldn't be complicated to add something like we have here https://github.com/jwalton/gh-find-current-pr/blob/master/src/main.ts inside code-coverage-action and call this logic only for 'push' events. Let me know if you have any other thoughts on this.
This is quite common issue and a lot of workflows are built on top of 'push' events, so I am sure more people would benefit from this out of the box support of 'push' events.