Skip to content

Commit 85200be

Browse files
committed
docs: change configuration to release docs only during the release or by hand. Rollback config for building doc for PR. (#1239)
1 parent acbd8fb commit 85200be

File tree

2 files changed

+41
-6
lines changed

2 files changed

+41
-6
lines changed

.github/workflows/build-docs.yml

+37
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,37 @@
1+
name: Build Docs
2+
3+
on:
4+
pull_request:
5+
branches:
6+
- main
7+
paths:
8+
- 'docs/**'
9+
- 'mkdocs.yml'
10+
- 'Makefile'
11+
12+
push:
13+
branches:
14+
- main
15+
paths:
16+
- 'docs/**'
17+
- 'mkdocs.yml'
18+
- 'Makefile'
19+
20+
jobs:
21+
docs:
22+
runs-on: ubuntu-latest
23+
steps:
24+
- uses: actions/checkout@v3
25+
- name: Set up Python
26+
uses: actions/setup-python@v4
27+
with:
28+
python-version: "3.8"
29+
- name: Capture branch and tag
30+
id: branch_name
31+
run: |
32+
echo "SOURCE_BRANCH=${GITHUB_REF#refs/heads/}" >> $GITHUB_ENV
33+
echo "SOURCE_TAG=${GITHUB_REF#refs/tags/}" >> $GITHUB_ENV
34+
- name: Build docs website
35+
run: |
36+
echo "GIT_PYTHON_REFRESH=quiet"
37+
make build-docs-website

.github/workflows/on-doc-merge.yml renamed to .github/workflows/release-doc.yml

+4-6
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,10 @@
11
name: Docs
22

33
on:
4-
push:
5-
branches:
6-
- main
7-
paths:
8-
- "docs/**"
9-
- "mkdocs.yml"
4+
release:
5+
types:
6+
- published
7+
workflow_dispatch: {}
108

119
jobs:
1210
release-docs:

0 commit comments

Comments
 (0)