Skip to content

Commit 8043d50

Browse files
committed
ci: build and deploy docs
1 parent e6e5cb3 commit 8043d50

File tree

1 file changed

+12
-1
lines changed

1 file changed

+12
-1
lines changed

.github/workflows/ci.yml

Lines changed: 12 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ jobs:
2222
- run: pnpm test
2323
- run: pnpm build
2424

25-
publish:
25+
publish-and-deploy:
2626
needs: build-and-test
2727
runs-on: ubuntu-latest
2828
if: github.event_name == 'release'
@@ -39,3 +39,14 @@ jobs:
3939
env:
4040
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
4141
run: pnpm publish --access public
42+
- name: Build docs
43+
run: pnpm docs:build
44+
- name: Deploy docs to production server
45+
uses: easingthemes/ssh-deploy@main
46+
env:
47+
SSH_PRIVATE_KEY: ${{ secrets.SSH_PRIVATE_KEY }}
48+
REMOTE_HOST: ${{ secrets.SSH_HOST }}
49+
REMOTE_USER: ${{ secrets.SSH_USER }}
50+
REMOTE_PORT: ${{ secrets.SSH_PORT }}
51+
SOURCE: "docs/.vitepress/dist"
52+
TARGET: ${{ secrets.TARGET_DIR_DOCS }}

0 commit comments

Comments
 (0)