hugo server
Watching for changes in /Users/zhangyang/github/my-blog/{archetypes,assets,content,data,i18n,layouts,static,themes}
Watching for config changes in /Users/zhangyang/github/my-blog/hugo.toml, /Users/zhangyang/github/my-blog/themes/ananke/config.yaml
Start building sites …
hugo v0.122.0-b9a03bd59d5f71a529acb3e33f995e0ef332b3aa+extended darwin/arm64 BuildDate=2024-01-26T15:54:24Z VendorInfo=brew
Built in 33 ms
Environment: “development”
Serving pages from memory
Running in Fast Render Mode. For full rebuilds on change: hugo server –disableFastRender
Web Server is available at http://localhost:1313/ (bind address 127.0.0.1)
Press Ctrl+C to stop
;; ox-hugo configuration(with-eval-after-load'org-capture(defunorg-hugo-new-subtree-post-capture-template()"Returns `org-capture' template string for new Hugo post
See `org-capture-templates' for more information."(let*((title(read-from-minibuffer"Post Title: "));Prompt to enter the post title(fname(org-hugo-slugtitle)))(mapconcat#'identity`(,(concat"* TODO "title)":PROPERTIES:",(concat":EXPORT_FILE_NAME: "fname)":END:""%?\n");Place the cursor here finally"\n")))(add-to-list'org-capture-templates'("h";`org-capture' binding + h"Hugo post"entry;; It is assumed that below file is present in `org-directory';; and that it has a "Blog Ideas" heading. It can even be a;; symlink pointing to the actual location of all-posts.org!(file+olp"all-posts.org""INBOX")(functionorg-hugo-new-subtree-post-capture-template))))
# Sample workflow for building and deploying a Hugo site to GitHub Pagesname:Deploy Hugo site to Pageson:# Runs on pushes targeting the default branchpush:branches:- main# Allows you to run this workflow manually from the Actions tabworkflow_dispatch:# Sets permissions of the GITHUB_TOKEN to allow deployment to GitHub Pagespermissions:contents:readpages:writeid-token:write# Allow only one concurrent deployment, skipping runs queued between the run in-progress and latest queued.# However, do NOT cancel in-progress runs as we want to allow these production deployments to complete.concurrency:group:"pages"cancel-in-progress:false# Default to bashdefaults:run:shell:bashjobs:# Build jobbuild:runs-on:ubuntu-latestenv:HUGO_VERSION:0.122.0steps:- name:Install Hugo CLIrun:| wget -O ${{ runner.temp }}/hugo.deb https://github.com/gohugoio/hugo/releases/download/v${HUGO_VERSION}/hugo_extended_${HUGO_VERSION}_linux-amd64.deb \
&& sudo dpkg -i ${{ runner.temp }}/hugo.deb- name:Install Dart Sassrun:sudo snap install dart-sass- name:Checkoutuses:actions/checkout@v4with:submodules:recursivefetch-depth:0- name:Setup Pagesid:pagesuses:actions/configure-pages@v4- name:Install Node.js dependenciesrun:"[[ -f package-lock.json || -f npm-shrinkwrap.json ]] && npm ci || true"- name:Build with Hugoenv:# For maximum backward compatibility with Hugo modulesHUGO_ENVIRONMENT:productionHUGO_ENV:productionrun:| hugo \
--gc \
--minify \
--baseURL "${{ steps.pages.outputs.base_url }}/"- name:Upload artifactuses:actions/upload-pages-artifact@v2with:path:./public# Deployment jobdeploy:environment:name:github-pagesurl:${{ steps.deployment.outputs.page_url }}runs-on:ubuntu-latestneeds:buildsteps:- name:Deploy to GitHub Pagesid:deploymentuses:actions/deploy-pages@v3