Skip to content

Commit

Permalink
use actions-gh-pages
Browse files Browse the repository at this point in the history
  • Loading branch information
gandalfr-KY committed Jun 5, 2024
1 parent e4aad5e commit 8eb8e17
Showing 1 changed file with 6 additions and 11 deletions.
17 changes: 6 additions & 11 deletions .github/workflows/build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -36,14 +36,9 @@ jobs:
emcc src/cpp/matrix.cpp -o build/matrix.js -lembind -std=c++17 -s WASM=2
- name: Deploy to GitHub Pages
if: github.ref == 'refs/heads/main'
run: |
git config --global user.name 'github-actions[bot]'
git config --global user.email 'github-actions[bot]@users.noreply.github.com'
git clone --depth 1 --branch gh-pages https://github.com/${{ github.repository }} gh-pages
rsync -av --delete build/ gh-pages/
cd gh-pages
git add .
git commit -m 'Deploy to GitHub Pages'
git push origin gh-pages
uses: peaceiris/actions-gh-pages@v3
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: ./build
publish_branch: gh-pages

0 comments on commit 8eb8e17

Please sign in to comment.