Skip to content

Commit

Permalink
Only build documentation when tests have completed
Browse files Browse the repository at this point in the history
  • Loading branch information
rlouf committed Sep 19, 2022
1 parent 8989da9 commit 3cfd6c5
Show file tree
Hide file tree
Showing 2 changed files with 14 additions and 8 deletions.
10 changes: 8 additions & 2 deletions .github/workflows/build_documentation.yml
Original file line number Diff line number Diff line change
@@ -1,14 +1,20 @@
name: Build the documentation

on:
pull_request:
branches: [main]
push:
branches: [main]
pull_request:
on:
workflow_run:
workflows: ["Tests"]
branches: [main]
types:
- completed

jobs:
build:
name: Build
if: ${{ github.event.workflow_run.conclusion == 'success' }}
runs-on: ubuntu-latest
steps:
- name: Checkout the branch
Expand Down
12 changes: 6 additions & 6 deletions .github/workflows/publish_documentation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,12 +2,12 @@ name: Publish the documentation

on:
push:
on:
workflow_run:
workflows: ["Build the documentation"]
branches: [main]
types:
- completed
on:
workflow_run:
workflows: ["Build the documentation"]
branches: [main]
types:
- completed

jobs:
publish:
Expand Down

0 comments on commit 3cfd6c5

Please sign in to comment.