commit ba3ceafe1751d321fbf8a96a9e97b3ca92c3cf3b parent 9a5bf3a82693ab5f2094a9524a74c847260d24db Author: minerva-jupiter <ryouturn@gmail.com> Date: Wed, 9 Sep 2026 04:40:15 +0900 ci(workflow): update GitHub Pages deployment to use PORTAL_PAT Diffstat:
| M | .github/workflows/stagit-build.yml | | | 19 | ++++++++++++++----- |
1 file changed, 14 insertions(+), 5 deletions(-)
diff --git a/.github/workflows/stagit-build.yml b/.github/workflows/stagit-build.yml @@ -58,8 +58,17 @@ jobs: (cd "${ROOT_DIR}/repositories" && stagit-index *.git > "${ROOT_DIR}/html/index.html") - - name: Deploy to GitHub Pages - uses: peaceiris/actions-gh-pages@main - with: - github_token: ${{ secrets.GITHUB_TOKEN }} - publish_dir: ./html + - name: Push ./html to gh-pages branch + env: + GH_TOKEN: ${{ secrets.PORTAL_PAT }} + run: | + cd html + git init + git config user.name "github-actions[bot]" + git config user.email "github-actions[bot]@users.noreply.github.com" + + git add -A + git commit -m "deploy: update stagit portal site [skip ci]" + + # PORTAL_PAT を使って gh-pages ブランチに強制プッシュ + git push -f "https://x-access-token:${GH_TOKEN}@github.com/${{ github.repository }}.git" HEAD:gh-pages