diff --git a/.github/dependabot.yml b/.github/dependabot.yml index 32c1c4779..19ce61f30 100644 --- a/.github/dependabot.yml +++ b/.github/dependabot.yml @@ -18,6 +18,12 @@ updates: commit-message: prefix: "chore(deps)" include: "scope" + # One pull request for the whole weekly update instead of one per + # dependency, each of which ran every workflow on its own. + groups: + maven-dependencies: + patterns: + - "*" # Enable version updates for GitHub Actions - package-ecosystem: "github-actions" @@ -35,6 +41,6 @@ updates: commit-message: prefix: "chore(ci)" groups: - codeql-action: + github-actions: patterns: - - "github/codeql-action*" + - "*" diff --git a/.github/workflows/codeql.yml b/.github/workflows/codeql.yml index 970cc1bd0..6f08c1500 100644 --- a/.github/workflows/codeql.yml +++ b/.github/workflows/codeql.yml @@ -8,6 +8,13 @@ on: schedule: - cron: '30 1 * * 0' # Weekly on Sundays at 1:30 AM +# A new push to a pull request (or a Dependabot rebase) cancels the run it +# replaces instead of stacking another one behind it. Every other trigger is +# keyed by commit, so each commit on main still gets its own run. +concurrency: + group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.sha }} + cancel-in-progress: ${{ github.event_name == 'pull_request' }} + jobs: analyze: name: Analyze diff --git a/.github/workflows/commitlint.yml b/.github/workflows/commitlint.yml index 84e3d7059..75e7a3159 100644 --- a/.github/workflows/commitlint.yml +++ b/.github/workflows/commitlint.yml @@ -23,6 +23,13 @@ on: permissions: contents: read +# A new push to a pull request (or a Dependabot rebase) cancels the run it +# replaces instead of stacking another one behind it. Every other trigger is +# keyed by commit, so each commit on main still gets its own run. +concurrency: + group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.sha }} + cancel-in-progress: ${{ github.event_name == 'pull_request' }} + jobs: commitlint: runs-on: ubuntu-latest diff --git a/.github/workflows/java.yml b/.github/workflows/java.yml index ab3f419b9..3d0e8d573 100644 --- a/.github/workflows/java.yml +++ b/.github/workflows/java.yml @@ -21,6 +21,17 @@ on: push: branches: - main + +permissions: + contents: read + +# A new push to a pull request (or a Dependabot rebase) cancels the run it +# replaces instead of stacking another one behind it. Every other trigger is +# keyed by commit, so each commit on main still gets its own run. +concurrency: + group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.sha }} + cancel-in-progress: ${{ github.event_name == 'pull_request' }} + jobs: build: runs-on: ubuntu-latest