-
Notifications
You must be signed in to change notification settings - Fork 31
43 lines (37 loc) · 1.09 KB
/
update-docs.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
name: Update documentation
on:
workflow_run:
workflows: ["Publish release"]
branches:
- main
types:
- completed
jobs:
deploy:
runs-on: ubuntu-latest
if: ${{ github.event.workflow_run.conclusion == 'success' }}
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Setup Node.js
uses: actions/setup-node@v4
with:
node-version: '20.x'
- name: Git config
run: |
git config user.name "${GITHUB_ACTOR}"
git config user.email "${GITHUB_ACTOR}@users.noreply.github.com"
- name: Install dependencies
run: npm ci
- name: Build documentation
run: |
npm run build
cp dist/design-angular-kit-bundle/index.html dist/design-angular-kit-bundle/404.html
- name: Publish on gh-pages
run: |
git remote set-url origin https://git:${GITHUB_TOKEN}@github.com/${GITHUB_REPOSITORY}.git
npm run documentation-deploy-to-gh-pages
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}