ci: drop pull_request triggers + add cancel-in-progress concurrency
test-go / test (push) Successful in 35s
test-web / test (push) Successful in 37s
android / Build + lint + test (push) Successful in 4m13s
android / Build signed release APK (push) Has been skipped
test-go / integration (push) Successful in 13m25s

Every commit on dev that's part of an open PR fires each workflow
TWICE: once for the push event and once for the pull_request event
(observable in run #43 + #44 for the same SHA in android.yml, same
shape across test-web.yml and test-go.yml). The two runs check the
exact same SHA — pure waste.

Drop the pull_request trigger from test-web.yml, test-go.yml, and
android.yml. The dev push already exercises every check that a PR
would re-run. This repo has no fork PRs to cover, which is the only
case pull_request would catch that push doesn't.

Add a concurrency group keyed on workflow + ref with
cancel-in-progress: true to every workflow including release.yml.
Rapid re-pushes (or force-moving the per-day tag) now cancel the
older in-flight run instead of stacking.
This commit is contained in:
2026-06-01 14:39:09 -04:00
parent 8db488b8ab
commit 90bfcaa388
4 changed files with 31 additions and 23 deletions
+6 -4
View File
@@ -17,10 +17,12 @@ on:
paths: paths:
- 'android/**' - 'android/**'
- '.gitea/workflows/android.yml' - '.gitea/workflows/android.yml'
pull_request:
branches: [main] # pull_request trigger intentionally omitted — see test-web.yml for
paths: # the rationale (single-author repo, push covers PR-merge equivalent).
- 'android/**' concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
env: env:
# Silences the JDK 22+ "restricted method in java.lang.System has been # Silences the JDK 22+ "restricted method in java.lang.System has been
+7
View File
@@ -26,6 +26,13 @@ on:
- '**/*.md' - '**/*.md'
workflow_dispatch: workflow_dispatch:
# Force-moving the per-day tag (or rapidly re-pushing to main) should
# supersede the in-flight build — the operator explicitly wants the
# later commit to win.
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs: jobs:
release: release:
runs-on: go-ci runs-on: go-ci
+6 -11
View File
@@ -31,17 +31,12 @@ on:
- 'cmd/**' - 'cmd/**'
- '.golangci.yml' - '.golangci.yml'
- '.gitea/workflows/test-go.yml' - '.gitea/workflows/test-go.yml'
pull_request:
branches: [main] # pull_request trigger intentionally omitted — see test-web.yml for
paths: # the rationale (single-author repo, push covers PR-merge equivalent).
- '**/*.go' concurrency:
- 'go.mod' group: ${{ github.workflow }}-${{ github.ref }}
- 'go.sum' cancel-in-progress: true
- 'sqlc.yaml'
- 'internal/**'
- 'cmd/**'
- '.golangci.yml'
- '.gitea/workflows/test-go.yml'
jobs: jobs:
test: test:
+12 -8
View File
@@ -1,8 +1,10 @@
name: test-web name: test-web
# Web SPA: vitest + svelte-check. Runs on push to dev/main and PRs to # Web SPA: vitest + svelte-check. Runs on push to dev/main only —
# main, scoped to web/** changes only — Go-only or Flutter-only diffs # the `pull_request` trigger is intentionally omitted because every
# don't trigger this workflow. # branch on this repo is local-only (no fork PRs), so the dev push
# fully covers what a PR run would re-execute. Keeping both events
# doubled CI cost on every commit.
on: on:
push: push:
@@ -10,11 +12,13 @@ on:
paths: paths:
- 'web/**' - 'web/**'
- '.gitea/workflows/test-web.yml' - '.gitea/workflows/test-web.yml'
pull_request:
branches: [main] # Cancel an earlier in-flight run for the same ref when a newer
paths: # commit arrives. With cancel-in-progress, rapid re-pushes don't
- 'web/**' # pile up zombie runs.
- '.gitea/workflows/test-web.yml' concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true
jobs: jobs:
test: test: