Update the old version of hugo and update the blog.
语速
Since the previously used Hugo version was too low and updating it would require significant effort, I have now updated Hugo, allowing me to focus solely on writing articles.
Because my Hugo source files and <username>.github.io are not in the same repository—meaning I cannot directly configure gh-pages using a branch—I have adjusted the workflow to suit my situation. Here is my workflow configuration file:
name:Deploy to Github Pageson:push:branches:[master]pull_request:branches:[master]jobs:build:runs-on:ubuntu-latestpermissions:# Give the default GITHUB_TOKEN write permission to commit and push the# added or changed files to the repository.contents:writesteps:- uses:actions/checkout@v4with:fetch-depth:0- name:Cache Hugo resourcesuses:actions/cache@v4env:cache-name:cache-hugo-resourceswith:path:resourceskey:${{ env.cache-name }}- uses:actions/setup-go@v5with:go-version:"^1.17.0"- run:go version- name:Setup Hugouses:peaceiris/actions-hugo@v2with:hugo-version:"latest"extended:true- name:Buildrun:hugo --minify --gc- name:Deployuses:peaceiris/actions-gh-pages@v3with:personal_token:${{ secrets.ACCESS_TOKEN }}external_repository:svtter/svtter.github.iopublish_branch:masterpublish_dir:./public