Merge pull request #136 from tetrabiodistributed/add-store-link #28
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: Build w/ Hugo & deploy to GitHub Pages | |
on: | |
push: | |
branches: | |
- deploy | |
jobs: | |
deploy: | |
runs-on: ubuntu-22.04 | |
steps: | |
- uses: actions/checkout@v2 | |
with: | |
submodules: recursive # Fetch Hugo themes | |
fetch-depth: 0 # Fetch all history for .GitInfo and .Lastmod | |
- name: Fix git safe.directory in container | |
run: mkdir -p /home/runner/work/_temp/_github_home && printf "[safe]\n\tdirectory = /github/workspace" > /home/runner/work/_temp/_github_home/.gitconfig | |
- name: Mark github workspace as safe | |
run: | | |
git config --global --add safe.directory /github/workspace | |
- name: Update submodules | |
uses: srt32/git-actions@v0.0.3 | |
with: | |
args: git submodule update --init --recursive | |
- name: Build | |
run: bash build.sh | |
- name: Deploy | |
uses: peaceiris/actions-gh-pages@v3 | |
with: | |
deploy_key: ${{ secrets.ACTIONS_DEPLOY_KEY }} | |
# or github_token: ${{ secrets.GITHUB_TOKEN }} | |
publish_branch: gh-pages | |
publish_dir: ./public |