File tree Expand file tree Collapse file tree 1 file changed +48
-0
lines changed Expand file tree Collapse file tree 1 file changed +48
-0
lines changed Original file line number Diff line number Diff line change 1+ name : Build and deploy an updated version of the website
2+
3+ on :
4+ push
5+
6+ jobs :
7+ build :
8+ runs-on : ubuntu-latest
9+ steps :
10+ - name : Checkout CoderBotOrg/docs
11+ uses : actions/checkout@v2
12+ with :
13+ repository : CoderBotOrg/docs
14+ path : folder/repo
15+
16+ - name : Checkout CoderBotOrg/docs
17+ uses : actions/checkout@v2
18+ with :
19+ repository : CoderBotOrg/docs
20+ ref : master
21+ path : folder/build
22+
23+ - uses : actions/setup-node@v1
24+ with :
25+ node-version : ' 12'
26+
27+ - name : Install npm dependencies
28+ working-directory : folder/repo/
29+ run : |
30+ npm install
31+
32+ - working-directory : folder/
33+ run : |
34+ cd repo
35+ npx vuepress build pages/
36+ mkdir dist
37+ cp pages/.vuepress/dist/* dist/ -r
38+ cd ..
39+ cp -a repo/dist/. build/
40+ cd build
41+ mkdir -m 700 ~/.ssh
42+ echo "${{ secrets.SSH_KEY_SECRET }}" > ~/.ssh/id_ed25519
43+ chmod 0600 ~/.ssh/id_ed25519
44+ git config --local user.name "GitHub Action"
45+ git config --global user.email "support@coderbot.org"
46+ echo "docs.coderbot.org" > CNAME
47+ git add .
48+ git commit -m "Update build" && git push || :
You can’t perform that action at this time.
0 commit comments