Skip to content

Commit 996121a

Browse files
committed
feat: add github action script
1 parent 4df5412 commit 996121a

File tree

2 files changed

+40
-0
lines changed

2 files changed

+40
-0
lines changed

.github/workflows/wangdoc.yml

+36
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
name: Linux tutorial CI
2+
on:
3+
push:
4+
branches:
5+
- main
6+
7+
jobs:
8+
page-generator:
9+
name: Generating pages
10+
runs-on: ubuntu-latest
11+
steps:
12+
- name: Checkout
13+
uses: actions/checkout@v4
14+
with:
15+
persist-credentials: false
16+
- name: Setup Node.js
17+
uses: actions/setup-node@v4
18+
with:
19+
node-version: 'latest'
20+
- name: Install dependencies
21+
run: npm install
22+
- name: Build pages
23+
run: npm run build
24+
- name: Deploy to website
25+
uses: JamesIves/github-pages-deploy-action@v4
26+
with:
27+
git-config-name: wangdoc-bot
28+
git-config-email: [email protected]
29+
repository-name: wangdoc/website
30+
token: ${{ secrets.WANGDOC_BOT_TOKEN }}
31+
branch: master # The branch the action should deploy to.
32+
folder: dist # The folder the action should deploy.
33+
target-folder: dist/linux
34+
clean: true # Automatically remove deleted files from the deploy branch
35+
commit-message: update from Linux tutorial
36+

loppo.yml

+4
Original file line numberDiff line numberDiff line change
@@ -6,3 +6,7 @@ customization: false
66
themeDir: loppo-theme
77
direction: ltr
88
id: linux
9+
branch: main
10+
hasComments: true
11+
isTutorial: true
12+

0 commit comments

Comments
 (0)