Skip to content

Merge pull request #10 from volcengine/fix/base-path #10

Merge pull request #10 from volcengine/fix/base-path

Merge pull request #10 from volcengine/fix/base-path #10

Workflow file for this run

# 构建 VitePress 站点并将其部署到 GitHub Pages 的示例工作流程
#
name: Deploy VitePress site to Pages
on:
push:
branches:
- main
- feat/docs
paths:
- 'docs/**'
- '.github/workflows/deploy-docs.yml'
# 允许你从 Actions 选项卡手动运行此工作流程
workflow_dispatch:
permissions:
contents: write
jobs:
build-and-deploy:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v5
with:
fetch-depth: 0
- name: Setup Node
uses: actions/setup-node@v6
with:
node-version: '22'
- name: Install dependencies
run: |
cd docs
echo "Check current directory"
pwd
npm ci
- name: Build with VitePress
run: |
cd docs
echo "Check current directory"
pwd
npm run docs:build
- name: Deploy to feat/deploy
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: docs/.vitepress/dist
publish_branch: feat/deploy
user_name: 'github-actions[bot]'
user_email: 'github-actions[bot]@users.noreply.github.com'
commit_message: 'Deploy docs to feat/deploy'