Don't skip firmware jobs if workflow is run manually (#3821)
* add workflow dispatch and check * single quotes * undo hack
This commit is contained in:
parent
2af87568e9
commit
9215d1b2dd
|
@ -1,6 +1,6 @@
|
|||
name: FW
|
||||
|
||||
on: [push, pull_request]
|
||||
on: [push, pull_request, workflow_dispatch]
|
||||
|
||||
jobs:
|
||||
build-firmware:
|
||||
|
@ -194,9 +194,9 @@ jobs:
|
|||
|
||||
steps:
|
||||
- name: Execution throttle early exit
|
||||
if: ${{ matrix.skip-rate }}
|
||||
# todo: how do we produce well-defined releases with skip-rate approach? For I can think of hacking the line below before a release
|
||||
run: if (($(($RANDOM % 100)) < ${{ matrix.skip-rate }})); then echo "skip=not_true" >> $GITHUB_ENV; fi
|
||||
# Don't skip any jobs if this workflow was run manually.
|
||||
if: ${{ matrix.skip-rate && github.event_name != 'workflow_dispatch' }}
|
||||
run: if (($(($RANDOM % 100)) < ${{ matrix.skip-rate }})); then echo "skip=true" >> $GITHUB_ENV; fi
|
||||
|
||||
- uses: actions/checkout@v1
|
||||
if: ${{ env.skip != 'true' }}
|
||||
|
|
Loading…
Reference in New Issue