Updated workflow
Build Sphinx Documentation / Build Documentation from PR Branch (pull_request) Successful in 2s
Build Sphinx Documentation / Build Documentation from PR Branch (pull_request) Successful in 2s
This commit is contained in:
@@ -11,7 +11,7 @@ jobs:
|
||||
runs-on: linux
|
||||
|
||||
steps:
|
||||
# 第一步:设置主工作树和虚拟环境
|
||||
# 第一步: 设置主工作树和虚拟环境
|
||||
- name: Setup main worktree and virtual environment
|
||||
run: |
|
||||
echo "=== Setting up main worktree ==="
|
||||
@@ -42,7 +42,7 @@ jobs:
|
||||
|
||||
echo "✓ Main worktree ready"
|
||||
|
||||
# 第二步:为PR分支创建工作树
|
||||
# 第二步: 为PR分支创建工作树
|
||||
- name: Create worktree for PR branch
|
||||
run: |
|
||||
echo "=== Creating worktree for PR branch: ${{ github.head_ref }} ==="
|
||||
@@ -63,7 +63,7 @@ jobs:
|
||||
|
||||
echo "✓ Worktree created at: /home/ly0kos/work/test_env/worktrees/${{ github.head_ref }}"
|
||||
|
||||
# 第三步:复用共享虚拟环境并检查依赖更新
|
||||
# 第三步: 复用共享虚拟环境并检查依赖更新
|
||||
- name: Reuse shared virtual environment
|
||||
run: |
|
||||
echo "=== Reusing shared virtual environment ==="
|
||||
@@ -92,7 +92,7 @@ jobs:
|
||||
echo "python3: $(python3 --version)"
|
||||
echo "Sphinx: $(sphinx-build --version 2>/dev/null || echo 'Not installed')"
|
||||
|
||||
# 第四步:在工作树中构建文档
|
||||
# 第四步: 在工作树中构建文档
|
||||
- name: Build documentation in worktree
|
||||
run: |
|
||||
echo "=== Building documentation in worktree ==="
|
||||
@@ -111,13 +111,13 @@ jobs:
|
||||
|
||||
echo "✓ Build completed for PR branch: ${{ github.head_ref }}"
|
||||
|
||||
# 第五步:验证构建结果
|
||||
# 第五步: 验证构建结果
|
||||
- name: Verify build
|
||||
run: |
|
||||
echo "Build output for PR ${{ github.head_ref }}:"
|
||||
ls -la /home/ly0kos/work/test_env/pr-builds/${{ github.head_ref }}/ | head -10
|
||||
|
||||
# 第六步:复制至测试目录
|
||||
# 第六步: 复制至测试目录
|
||||
- name: Copy to dev folder
|
||||
run: |
|
||||
echo "Now clear dev folder"
|
||||
@@ -125,4 +125,5 @@ jobs:
|
||||
echo "Copy build to dev folder"
|
||||
cp -r /home/ly0kos/work/test_env/pr-builds/${{ github.head_ref }}/* /var/www/docs_dev/
|
||||
echo "✓ Documentation in DEV folder now!"
|
||||
echo "Please check http://mkb.local:880 to Verify Changes"
|
||||
echo "Please check http://mkb.local:880 to Verify Changes"
|
||||
|
||||
|
||||
Reference in New Issue
Block a user