Skip to content

Commit

Permalink
Use local checkout of cancel-workflow-runs; revert scheduled
Browse files Browse the repository at this point in the history
  • Loading branch information
ktmud committed Jan 25, 2021
1 parent 28459a4 commit dfc623d
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 5 deletions.
1 change: 1 addition & 0 deletions .github/actions/cancel-workflow-runs
Submodule cancel-workflow-runs added at 953e05
17 changes: 12 additions & 5 deletions .github/workflows/cancel_duplicates.yml
Original file line number Diff line number Diff line change
@@ -1,9 +1,10 @@
name: Cancel Duplicates
on:
# Checks for duplicate jobs on every push (merge) and every 10 minutes
push:
schedule:
- cron: "*/10 * * * *"
workflow_run:
workflows:
- "Miscellaneous"
types:
- requested

jobs:
cancel-duplicate-runs:
Expand All @@ -25,7 +26,13 @@ jobs:
echo "Found $count unfinished jobs."
echo "::set-output name=count::$count"
- uses: potiuk/cancel-workflow-runs@953e057dc81d3458935a18d1184c386b0f6b5738
- name: "Checkout ${{ github.ref }} ( ${{ github.sha }} )"
uses: actions/checkout@v2
with:
persist-credentials: false
submodules: recursive

- uses: .github/actions/cancel-workflow-runs@953e057dc81d3458935a18d1184c386b0f6b5738
name: "Cancel duplicate workflow runs"
if: steps.check_queued.outputs.count >= 20
with:
Expand Down

0 comments on commit dfc623d

Please sign in to comment.