Skip to content

Commit c022410

Browse files
committed
ci: Move docs build to specific workflow
1 parent 2bfaff7 commit c022410

2 files changed

Lines changed: 38 additions & 15 deletions

File tree

.github/workflows/docs.yml

Lines changed: 38 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,38 @@
1+
name: 'Build and Publish docs'
2+
3+
on:
4+
push:
5+
tags:
6+
- 'v[0-9].[0-9]+.[0-9]'
7+
workflow_dispatch:
8+
9+
jobs:
10+
build-publish-docs:
11+
runs-on: ubuntu-latest
12+
steps:
13+
- name: Set up checkout
14+
uses: actions/checkout@v3
15+
with:
16+
fetch-depth: 0
17+
18+
- name: Set up yarn (Node 18)
19+
uses: actions/setup-node@v3
20+
with:
21+
node-version: 18
22+
cache: 'yarn'
23+
24+
- name: Install dependencies
25+
run: yarn install
26+
27+
## Docs
28+
29+
- name: Build docs
30+
run: yarn build:doc
31+
32+
- run: |
33+
git config --global user.name "github-actions[bot]"
34+
git config --global user.email "github-actions[bot]@users.noreply.github.com"
35+
36+
- uses: kiprasmel/git-publish-generated-branch@v0
37+
with:
38+
ARGS: '--dir "docs" --branch "ph-pages"'

.github/workflows/release.yml

Lines changed: 0 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -11,8 +11,6 @@ jobs:
1111
steps:
1212
- name: Set up checkout
1313
uses: actions/checkout@v3
14-
with:
15-
fetch-depth: 0
1614

1715
- name: Set up yarn (Node 18)
1816
uses: actions/setup-node@v3
@@ -30,16 +28,3 @@ jobs:
3028
run: yarn run publish
3129
env:
3230
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
33-
34-
## Docs
35-
36-
- name: Build docs
37-
run: yarn build:doc
38-
39-
- run: |
40-
git config --global user.name "github-actions[bot]"
41-
git config --global user.email "github-actions[bot]@users.noreply.github.com"
42-
43-
- uses: kiprasmel/git-publish-generated-branch@v0
44-
with:
45-
ARGS: '--dir "docs" --branch "ph-pages"'

0 commit comments

Comments
 (0)