Skip to content

Commit 019653c

Browse files
committed
fix(ci): serialize docs deployments to gh-pages
Concurrent pushes to main started overlapping docs builds; the last to finish was rejected as non-fast-forward, and an older commit could overwrite newer docs. Pull request previews never push and stay unserialized.
1 parent f415b82 commit 019653c

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

‎.github/workflows/deploy_sphinx_docs.yml‎

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -21,6 +21,11 @@ on:
2121
type: boolean
2222
default: false
2323

24+
# Serialize gh-pages deployments so concurrent runs cannot push from a stale branch.
25+
concurrency:
26+
group: ${{ github.event_name == 'pull_request' && format('docs-preview-{0}', github.run_id) || 'docs-deploy-gh-pages' }}
27+
cancel-in-progress: false
28+
2429
jobs:
2530
pages:
2631
runs-on: ubuntu-latest

0 commit comments

Comments
 (0)