diff options
author | dsrkafuu | 2022-02-25 00:37:02 +0800 |
---|---|---|
committer | dsrkafuu | 2022-02-25 00:37:02 +0800 |
commit | 94713fb248762941d8603bfae7764cd71a4e3f56 (patch) | |
tree | 6d56e70f68b0fd0f1bbd2d2a7d05a5059d1f23f6 /.github/workflows/pages.yml | |
parent | 57e0f041085cb65ec2ef52167f1eb102af478200 (diff) | |
download | hugo-theme-fuji-94713fb248762941d8603bfae7764cd71a4e3f56.tar.gz hugo-theme-fuji-94713fb248762941d8603bfae7764cd71a4e3f56.tar.bz2 hugo-theme-fuji-94713fb248762941d8603bfae7764cd71a4e3f56.zip |
feat: pages action
Diffstat (limited to '.github/workflows/pages.yml')
-rw-r--r-- | .github/workflows/pages.yml | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/.github/workflows/pages.yml b/.github/workflows/pages.yml new file mode 100644 index 0000000..fa8ab50 --- /dev/null +++ b/.github/workflows/pages.yml @@ -0,0 +1,36 @@ +name: pages + +on: + push: + branches: + - main + pull_request: + +jobs: + pages: + name: Pages Deployment + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + + - name: Setup Hugo + uses: peaceiris/actions-hugo@v2 + with: + hugo-version: 'latest' + + - name: Build + run: | + cd exampleSite + mkdir themes + ln -s ../.. themes/fuji + hugo + cd .. + + - name: Deploy + uses: peaceiris/actions-gh-pages@v3 + if: ${{ github.ref == 'refs/heads/main' }} + run: | + cd exampleSite + with: + github_token: ${{ secrets.GITHUB_TOKEN }} + publish_dir: ./public |