Create jekyll-gh-pages.yml #1
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 Docsify to GitHub Pages | |
on: | |
push: | |
branches: | |
- main | |
- dev | |
jobs: | |
deploy: | |
runs-on: ubuntu-latest | |
steps: | |
# Step 1: Checkout repository | |
- name: Checkout repository | |
uses: actions/checkout@v2 | |
# Step 2: Deploy docs folder to GitHub Pages | |
- name: Deploy to GitHub Pages | |
uses: JamesIves/github-pages-deploy-action@v4 | |
with: | |
branch: gh-pages # 部署到 gh-pages 分支 | |
folder: docs # 要部署的文件夹是 docs | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |