Skip to content

Build and deploy to jdheyburn.github.io #1064

Build and deploy to jdheyburn.github.io

Build and deploy to jdheyburn.github.io #1064

Workflow file for this run

name: Build and deploy to jdheyburn.github.io
on:
push:
branches:
- master
workflow_dispatch:
schedule:
- cron: "0 10 * * *"
jobs:
deploy:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v3
- name: Checkout submodules
shell: bash
run: |
auth_header="$(git config --local --get http.https://github.com/.extraheader)"
git submodule sync --recursive
git -c "http.extraheader=$auth_header" -c protocol.version=2 submodule update --init --force --recursive --depth=1
- name: Setup Hugo
uses: peaceiris/actions-hugo@v2
with:
hugo-version: "0.104.3"
extended: true
- name: Build
run: hugo --gc
- name: Copy CNAME
run: cp CNAME ./public/
- name: Deploy
uses: peaceiris/actions-gh-pages@v3
with:
deploy_key: ${{ secrets.DEPLOY_KEY }}
external_repository: jdheyburn/jdheyburn.github.io
publish_branch: master
publish_dir: ./public
commit_message: ${{ github.event.head_commit.message }}