forked from Bedrock-OSS/bedrock-wiki
-
Notifications
You must be signed in to change notification settings - Fork 0
60 lines (57 loc) · 2.07 KB
/
deploy.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
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
name: Deploy
on:
push:
branches:
- wiki
jobs:
deploy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v1
- name: Use Node.js
uses: actions/setup-node@v3
with:
node-version-file: .nvmrc
cache: npm
- name: Check eslint, Install and Build 🔧
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
run: |
npm install
npm run lint
npm run build
- name: Deploy 🚀
uses: JamesIves/[email protected]
with:
branch: generated
folder: docs/.vitepress/dist
- name: Bully someone into fixing it
if: ${{ failure() }}
uses: Bedrock-OSS/[email protected]
with:
webhook: https://canary.discord.com/api/webhooks/${{ secrets.WEBHOOK_ID }}/${{ secrets.WEBHOOK_TOKEN }}
tenorGifApiKey: ${{ secrets.TENOR_GIF_API_KEY }}
failMessage: I blame %author% <:PE_PandaBonk:885395101877166110>
failTitle: 'Wiki deployment failed!'
failAuthor: 'You messed up'
gifFailQuery: fail
successTitle: 'Wiki deployment succeeded!'
successMessage: Thank you, %author%! <:PE_PandaInLove:885395799029194853>
gifSuccessQuery: success
successAuthor: 'You did it'
failed: 'true'
- name: Send a message if previous build failed
if: ${{ success() }}
uses: Bedrock-OSS/[email protected]
with:
webhook: https://canary.discord.com/api/webhooks/${{ secrets.WEBHOOK_ID }}/${{ secrets.WEBHOOK_TOKEN }}
tenorGifApiKey: ${{ secrets.TENOR_GIF_API_KEY }}
failMessage: I blame %author% <:PE_PandaBonk:885395101877166110>
failTitle: 'Wiki deployment failed!'
failAuthor: 'You messed up'
gifFailQuery: fail
successTitle: 'Wiki deployment succeeded!'
successMessage: Thank you, %author%! <:PE_PandaInLove:885395799029194853>
gifSuccessQuery: success
successAuthor: 'You did it'
failed: 'false'