-
Notifications
You must be signed in to change notification settings - Fork 0
56 lines (48 loc) · 1.5 KB
/
gh-pages.yaml
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
44
45
46
47
48
49
50
51
52
53
54
55
56
name: site
on:
push:
branches:
- test
workflow_run:
workflows: ["build-deploy"]
types:
- completed
jobs:
publish:
runs-on: ubuntu-latest
strategy:
matrix:
node: ["14"]
name: gh-pages-publish
steps:
- uses: actions/checkout@v2
- uses: FranzDiebold/github-env-vars-action@v2
- uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node }}
- name: build
env:
BASE_URL: "https://${{env.CI_REPOSITORY_OWNER}}.github.io/${{env.CI_REPOSITORY_NAME}}/"
run: |
npm install
sed -i "s#history#hash#g" .env.production
npm run build
- uses: peaceiris/actions-gh-pages@v3
name: GitHub Pages Deploy
with:
publish_dir: "dist/"
github_token: ${{ secrets.GITHUB_TOKEN }}
- name: feishu-bot-message
if: always()
uses: foxundermoon/feishu-action@v2
with:
url: ${{ secrets.FEISHU_BOT_WEBHOOK_URL }}
msg_type: text
content: |
text: |
⭕️ 部署状态 - From Github Action
repository: https://github.com/${{ github.repository }}
committer: https://github.com/${{ github.actor }}
compare: ${{ github.event.compare }}
job status: ${{ job.status }}
online: https://${{env.CI_REPOSITORY_OWNER}}.github.io/${{env.CI_REPOSITORY_NAME}}/