Skip to content

release cs161

release cs161 #52

Workflow file for this run

name: Deploy to GitHub Pages
on:
push:
branches:
- main
pull_request:
permissions:
contents: read
pages: write
id-token: write
concurrency:
group: pages
cancel-in-progress: false
jobs:
build:
runs-on: ubuntu-22.04
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0 # Fetch all history for .GitInfo and .Lastmod
submodules: 'true'
token: ${{ secrets.PAT_FOR_PRIVATE_REPOS }}
- name: Build Link Index
uses: jackyzha0/hugo-obsidian@v2.18
with:
index: true
input: content
output: assets/indices
root: .
- name: Setup Hugo
uses: peaceiris/actions-hugo@v3
with:
hugo-version: '0.161.1'
extended: true
- name: Build
run: hugo --minify
- name: Upload artifact
if: github.event_name == 'push'
uses: actions/upload-pages-artifact@v3
with:
path: public
deploy:
needs: build
if: github.event_name == 'push'
environment:
name: github-pages
url: ${{ steps.deployment.outputs.page_url }}
runs-on: ubuntu-latest
steps:
- name: Deploy to GitHub Pages
id: deployment
uses: actions/deploy-pages@v4