Update main.yml #16
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: UICHCC Hugo to github pages deploy | |
on: | |
push: | |
branches: | |
- master | |
jobs: | |
build-deploy: | |
runs-on: ubuntu-22.04 | |
steps: | |
- uses: actions/checkout@v1 # v2 does not have submodules option now | |
# with: | |
# submodules: true | |
- name: Setup Hugo | |
uses: peaceiris/actions-hugo@v2 | |
with: | |
hugo-version: '0.62.2' | |
# extended: true | |
- name: prepare theme | |
run: git submodule sync && git submodule update --init | |
- name: Build | |
run: hugo --minify | |
- name: Deploy | |
uses: peaceiris/actions-gh-pages@v3 | |
with: | |
deploy_key: ${{ secrets.ACTIONS_DEPLOY_KEY }} | |
external_repository: uichcc/uichcc.github.io | |
publish_dir: ./public | |
publish_branch: master | |
keep_files: true |