example add picture #140
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Deploy_Docusaurus_Pages | |
on: | |
push: | |
branches: | |
- main | |
jobs: | |
deploy: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v2 | |
- name: Set up Node.js | |
uses: actions/setup-node@v2 | |
with: | |
node-version: '16' | |
- name: Install dependencies | |
run: yarn install | |
- name: Build the project | |
run: yarn build | |
- name: Configure Git | |
run: | | |
git config --global user.name "GitHub Actions Bot" | |
git config --global user.email "[email protected]" | |
- name: Deploy to GitHub Pages manually | |
env: | |
DEPLOY_TOKEN: ${{ secrets.DEPLOY_TOKEN }} | |
run: | | |
# Create a new Git repo in build directory | |
cd build | |
git init | |
git remote add origin https://x-access-token:${DEPLOY_TOKEN}@github.com/FPGA-MAFIA/fpga_mafia_wiki.git | |
git checkout -b gh-pages | |
git add . | |
git commit -m "Deploy website" | |
git push -u origin gh-pages --force |