Skip to main content
  1. Posts/

First Post: The Blog Is Live

·168 words·1 min
Author
lxapgjryzc

This blog runs on Hugo and GitHub Pages, and every post is published in English, Chinese, and Japanese. The whole pipeline looks like this:

  1. Write posts in Markdown under content/posts/
  2. git push to GitHub
  3. GitHub Actions runs hugo --minify
  4. The build output is published to GitHub Pages

From hitting save to seeing it live takes about a minute.

Writing a new post
#

Each post is three files sharing one base name, with the language code before the extension:

content/posts/some-title.en.md
content/posts/some-title.zh.md
content/posts/some-title.ja.md

Hugo links them together automatically, so the language switcher in the header jumps between versions of the same post rather than dumping you back on the home page.

Code blocks get syntax highlighting:

def greet(name: str) -> str:
    return f"Hello, {name}!"

Tables, blockquotes, images — all the usual Markdown works.

Images go in static/, and you reference them as /image-name.png.

Previewing locally
#

hugo server -D starts a local server with hot reload, so you can see changes as you type. Push once it looks right.