aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authordundargoc <gocdundar@gmail.com>2024-03-10 13:49:00 +0100
committerdundargoc <33953936+dundargoc@users.noreply.github.com>2024-03-16 15:00:09 +0100
commitbf24298feaeab9dd5fea197b4b4422fee31ac33c (patch)
tree9a3af3d031a18e8759ead52cbebe03649694d5e5
parent5da0d513b9ce1cc7e5458c14461ed4b0dad833da (diff)
downloadrneovim-bf24298feaeab9dd5fea197b4b4422fee31ac33c.tar.gz
rneovim-bf24298feaeab9dd5fea197b4b4422fee31ac33c.tar.bz2
rneovim-bf24298feaeab9dd5fea197b4b4422fee31ac33c.zip
ci: simplify concurrency string
`github.ref` is now defined for both pull requests and pushes, meaning that it can be used to simplify the concurrency group. `cancel-in-progress` is set to true only if the trigger is a pull request, as we don't want master runs to cancel each other out.
-rw-r--r--.github/workflows/build.yml4
-rw-r--r--.github/workflows/codeql.yml4
-rw-r--r--.github/workflows/optional.yml4
-rw-r--r--.github/workflows/test.yml4
4 files changed, 8 insertions, 8 deletions
diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml
index 13fa692be1..bf8356243e 100644
--- a/.github/workflows/build.yml
+++ b/.github/workflows/build.yml
@@ -12,8 +12,8 @@ on:
- '.github/**'
concurrency:
- group: ${{ github.workflow }}-${{ github.head_ref }}
- cancel-in-progress: true
+ group: ${{ github.workflow }}-${{ github.ref }}
+ cancel-in-progress: ${{ github.event_name == 'pull_request' }}
env:
BIN_DIR: ${{ github.workspace }}/bin
diff --git a/.github/workflows/codeql.yml b/.github/workflows/codeql.yml
index c2db78dd25..135e5321e5 100644
--- a/.github/workflows/codeql.yml
+++ b/.github/workflows/codeql.yml
@@ -1,8 +1,8 @@
name: "codeql"
concurrency:
- group: ${{ github.workflow }}-${{ github.event_name == 'pull_request' && github.head_ref || github.sha }}
- cancel-in-progress: true
+ group: ${{ github.workflow }}-${{ github.ref }}
+ cancel-in-progress: ${{ github.event_name == 'pull_request' }}
on:
push:
diff --git a/.github/workflows/optional.yml b/.github/workflows/optional.yml
index c9a8205f87..84d71821c5 100644
--- a/.github/workflows/optional.yml
+++ b/.github/workflows/optional.yml
@@ -5,8 +5,8 @@ on:
workflow_dispatch:
concurrency:
- group: ${{ github.workflow }}-${{ github.event_name == 'pull_request' && github.head_ref || github.sha }}
- cancel-in-progress: true
+ group: ${{ github.workflow }}-${{ github.ref }}
+ cancel-in-progress: ${{ github.event_name == 'pull_request' }}
env:
INSTALL_PREFIX: ${{ github.workspace }}/nvim-install
diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml
index 6bd40b8561..cf1ea48506 100644
--- a/.github/workflows/test.yml
+++ b/.github/workflows/test.yml
@@ -12,8 +12,8 @@ on:
- 'contrib/**'
concurrency:
- group: ${{ github.workflow }}-${{ github.event_name == 'pull_request' && github.head_ref || github.sha }}
- cancel-in-progress: true
+ group: ${{ github.workflow }}-${{ github.ref }}
+ cancel-in-progress: ${{ github.event_name == 'pull_request' }}
env:
ASAN_OPTIONS: detect_leaks=1:check_initialization_order=1:log_path=${{ github.workspace }}/build/log/asan:intercept_tls_get_addr=0