diff options
| author | FangcatChina <f20091219@outlook.com> | 2026-07-25 08:07:37 +0000 |
|---|---|---|
| committer | FangcatChina <f20091219@outlook.com> | 2026-07-25 08:07:37 +0000 |
| commit | 716545e37827c9800e2b5409406b075824f90c03 (patch) | |
| tree | b5a92d2300162ab45dcf5094b739c4847d77a247 /.github/workflows | |
| parent | New Workflow (diff) | |
Turn to Gitea
Diffstat (limited to '.github/workflows')
| -rw-r--r-- | .github/workflows/mkdocs-deploy.yml | 59 |
1 files changed, 0 insertions, 59 deletions
diff --git a/.github/workflows/mkdocs-deploy.yml b/.github/workflows/mkdocs-deploy.yml deleted file mode 100644 index e77f6fb..0000000 --- a/.github/workflows/mkdocs-deploy.yml +++ /dev/null @@ -1,59 +0,0 @@ -name: Deploy MkDocs to Another Repository - -on: - push: - branches: - - main - paths: - - 'docs/**' - - 'mkdocs.yml' - - 'overrides/**' - - '.github/workflows/mkdocs-deploy.yml' - workflow_dispatch: - -permissions: - contents: read - -concurrency: - group: "pages" - cancel-in-progress: false - -jobs: - build-and-deploy: - runs-on: ubuntu-latest - steps: - - name: Checkout source code - uses: actions/checkout@v4 - with: - fetch-depth: 0 - - - name: Set up Python - uses: actions/setup-python@v5 - with: - python-version: '3.13' - cache: 'pip' - - - name: Install MkDocs dependencies - run: | - python -m pip install --upgrade pip - pip install -r requirements.txt - - - name: Build MkDocs site - run: mkdocs build --strict - env: - DEPLOY_KEY: ${{ secrets.DEPLOY_KEY }} - - - name: Deploy to target repository - env: - TARGET_REPO: https://github.com/LinuxCabin/handbook-site - TARGET_BRANCH: gh-pages - # 个人访问令牌(需要有写入目标仓库的权限) - DEPLOY_TOKEN: ${{ secrets.DEPLOY_KEY }} - run: | - cd site - git init - git config user.name "github-actions[bot]" - git config user.email "github-actions[bot]@users.noreply.github.com" - git add . - git commit -m "Deploy site $(date -u '+%Y-%m-%d %H:%M:%S UTC')" - git push --force https://x-access-token:${DEPLOY_TOKEN}@${TARGET_REPO#https://} HEAD:${TARGET_BRANCH}
\ No newline at end of file |
