Skip to content

Commit 1ca8ba2

Browse files
authored
Merge pull request #8 from codeeshop-oc/codeeshop-oc-patch-1
Update deploy.yml
2 parents 8de60b1 + 9eae671 commit 1ca8ba2

File tree

1 file changed

+22
-27
lines changed

1 file changed

+22
-27
lines changed

.github/workflows/deploy.yml

Lines changed: 22 additions & 27 deletions
Original file line numberDiff line numberDiff line change
@@ -1,18 +1,17 @@
11
name: Deploy
22

33
on:
4-
push:
5-
branches:
6-
- main
4+
release:
5+
types: [created]
6+
7+
workflow_dispatch:
78

89
jobs:
910
lint:
1011
runs-on: ubuntu-latest
1112
steps:
1213
- uses: actions/checkout@v3
13-
with:
14-
fetch-depth: 0
15-
14+
1615
- uses: pnpm/action-setup@v2
1716
name: Install pnpm
1817
id: pnpm-install
@@ -25,27 +24,27 @@ jobs:
2524
shell: bash
2625
run: |
2726
echo "STORE_PATH=$(pnpm store path)" >> $GITHUB_OUTPUT
27+
2828
29-
- uses: actions/setup-node@v3
29+
- name: Set node
30+
uses: actions/setup-node@v3
3031
with:
31-
node-version: 16
32+
node-version: 16.x
3233
cache: pnpm
3334

34-
- name: Install Packages
35-
- run: pnpm i --frozen-lockfile
35+
- name: Install
36+
run: pnpm i
3637

3738
- name: Lint
3839
run: pnpm run lint
39-
40-
41-
deploy:
40+
41+
build:
4242
needs: lint
43+
name: Github Page Deploy
4344
runs-on: ubuntu-latest
4445
steps:
4546
- uses: actions/checkout@v3
46-
with:
47-
fetch-depth: 0
48-
47+
4948
- uses: pnpm/action-setup@v2
5049
name: Install pnpm
5150
id: pnpm-install
@@ -58,20 +57,16 @@ jobs:
5857
shell: bash
5958
run: |
6059
echo "STORE_PATH=$(pnpm store path)" >> $GITHUB_OUTPUT
60+
6161
62-
- uses: actions/setup-node@v3
62+
- name: Set node
63+
uses: actions/setup-node@v3
6364
with:
64-
node-version: 16
65+
node-version: 16.x
6566
cache: pnpm
6667

67-
- name: Install Packages
68-
- run: pnpm i --frozen-lockfile
68+
- name: Install
69+
run: pnpm i --frozen-lockfile
6970

7071
- name: Build
71-
run: yarn docs:build
72-
73-
- name: Deploy
74-
uses: peaceiris/actions-gh-pages@v3
75-
with:
76-
github_token: ${{ secrets.GITHUB_TOKEN }}
77-
publish_dir: docs/.vitepress/dist
72+
run: pnpm docs:build

0 commit comments

Comments
 (0)