Correct my note #155
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: publish | |
on: [push, workflow_dispatch] | |
jobs: | |
deploy: | |
runs-on: ubuntu-latest | |
steps: | |
- name: Git checkout | |
uses: actions/checkout@v4 | |
- uses: actions/setup-node@v4 | |
with: | |
node-version: "21.6.1" | |
- run: npm install | |
- run: npm run format | |
- name: Commit changes | |
uses: stefanzweifel/git-auto-commit-action@v5 | |
with: | |
commit_message: Apply formatting changes | |
branch: ${{ github.head_ref }} | |
- name: Retrieve theme | |
run: git submodule update --init --recursive | |
- name: Setup hugo | |
uses: peaceiris/actions-hugo@v2 | |
with: | |
hugo-version: "0.122.0" | |
extended: true | |
- name: Build | |
run: hugo --minify | |
- name: Add README | |
run: | | |
echo "This site is generated from github.com/bpcreech/blog" > ./public/README | |
- name: Grab latest asteroids build | |
uses: robinraju/[email protected] | |
with: | |
out-file-path: ./public/asteroids | |
repository: bpcreech/typescript-asteroids | |
latest: true | |
extract: true | |
- name: Deploy | |
uses: peaceiris/actions-gh-pages@v3 | |
with: | |
personal_token: ${{ secrets.TOKEN }} | |
external_repository: bpcreech/bpcreech.github.io | |
publish_dir: ./public | |
# keep_files: true | |
user_name: bpcreech | |
user_email: [email protected] | |
publish_branch: main | |
cname: bpcreech.com |