build: Cancel in-flight CodeQL workflow
@@ -15,7 +15,7 @@ env:
permissions:
security-events: write
- actions: read
+ actions: write
contents: read
jobs:
@@ -25,6 +25,11 @@ jobs:
- name: Checkout repository
uses: actions/checkout@v3
+ - name: Cancel previous run
+ uses: styfle/cancel-workflow-action@0.11.0
+ with:
+ access_token: ${{ secrets.GITHUB_TOKEN }}
+
- name: Initialize CodeQL
uses: github/codeql-action/init@v2
with:
