Files
Hugo/README.md
T
fukunee 6e758e2875 Switch quotations to curly double quotes
All articles replace corner brackets with curly double quotes, and nested quotes drop to single curly quotes per GB/T 15834.

The writing rules move out of README into their own WRITING.md, which records the new convention and now owns the pre-submit checklist.
2026-11-15 21:06:42 +08:00

171 lines
5.3 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# FuKun.Net
基于 [Hugo](https://gohugo.io/) + [Hextra](https://github.com/imfing/hextra) 构建的个人站点,部署在腾讯云 Lighthouse 自托管服务器上。
---
## 技术栈
| 层面 | 选型 |
|------|------|
| 静态生成器 | Hugo v0.161+ (extended) |
| 主题 | Hextra |
| CSS | Tailwind CSS v4(Hextra 内置) |
| 站内搜索 | FlexSearch(客户端全文搜索) |
| 字体 | iA Writer Quattro S(自托管) + Noto Sans SC(Google Fonts) |
| Web 服务器 | Nginx on Ubuntu 24.04 |
## 项目结构
```
Hugo/
├── hugo.yaml # 站点配置
├── README.md # 技术栈、结构、命令、配置、待办
├── WRITING.md # 写作规范:引用、立场、文风、排版、自检
│
├── content/
│ ├── _index.md # 首页(Hero + 最新文章)
│ ├── about.md # 关于页
│ └── blog/
│ ├── _index.md # 文章列表
│ └── *.md # 单篇文章
│
├── layouts/
│ ├── hextra-home.html # 自定义首页布局(覆盖主题)
│ ├── blog/single.html # 文章页(poet 打字机 + 分隔线)
│ ├── _default/single.html # 同上,非 blog 分区
│ ├── shortcodes/
│ │ ├── note.html # 边注 / 书目边注
│ │ └── caption.html # 图片说明
│ └── _partials/
│ └── custom/
│ └── head-end.html # 字体预加载
│
├── assets/
│ └── css/
│ └── custom.css # 字体覆盖、导航栏修复
│
├── i18n/
│ └── zh-cn.yaml # 覆盖页脚版权文案
│
├── static/
│ ├── images/
│ │ ├── logo.svg # FK 图标(浅色模式)
│ │ └── logo-dark.svg # FK 图标(深色模式)
│ ├── fonts/
│ │ └── iAWriterQuattroSRegular.ttf
│ └── js/
│ └── notes.js # 宽屏边注定位
│
├── themes/
│ ├── hextra/ # 当前主题
│ ├── PaperMod/ # 备用主题
│ ├── terminal/
│ └── minimal/
│
└── archetypes/
└── default.md # 新文章模板
```
## 常用命令
```bash
# 本地开发(热重载)
hugo server
# 包含草稿
hugo server -D
# 生产构建
hugo --gc --minify
# 新建文章
hugo new blog/文章名.md
# 预览其他主题
hugo server -t PaperMod
hugo server -t terminal
```
构建产物输出到 `public/`,通过 Nginx 提供服务。
## 关键配置
`hugo.yaml` 中的核心设置:
| 参数 | 值 | 说明 |
|------|-----|------|
| `baseURL` | `https://fukun.net/` | 生产环境域名 |
| `theme` | `hextra` | 当前主题 |
| `hasCJKLanguage` | `true` | 中日韩语言优化 |
| `navbar.displayTitle` | `false` | 导航栏仅显示图标 |
| `navbar.displayLogo` | `true` | 启用 40×40 FK 图标 |
| `search.type` | `flexsearch` | FlexSearch 全文搜索 |
| `blog.list.pagerSize` | `10` | 每页文章数 |
| `comments.enable` | `false` | 评论系统关闭 |
---
## 写作规范
文章的引用、立场、文风、排版、front matter、成篇取材、用词与交稿自检,全部写在 [`WRITING.md`](WRITING.md)。动笔前先读一遍;改稿、扩写、缩写、起标题同样适用。本文件(技术栈、目录、命令、配置、待办)不在写作规范的范围内。
三条最容易忘的:
- 引文必须能翻到原文,书目进 `{{< note cite >}}` 边注;正文不写“出处:……”,也不写“照录原文”这类交代。
- 正文零 `**加粗**`、零表格、零勾选清单、零目录树;并列项写进句子,或交给标题点出来。
- 一篇一个主张,用一句话说得出来;说不出来,就是两篇。
---
## TODO
### 品牌与图标
- [x] FK 手写书法风格图标,黑底 `#111`,白字
- [x] 浅色/深色双版图标(`logo.svg` / `logo-dark.svg`)
- [x] 导航栏仅显示图标,隐藏标题文字,40×40px
- [x] 多平台 favicon 适配
- [ ] favicon优化
- [ ] 自定义 OG 社交分享图(1200×630)
- [ ] iOS/Android 触屏图标
### 首页(参考 Dan Koe 风格)
- [x] Hero 标题:**FuKun**
- [x] 副标题:*FuKun.Net — Tech notes & life*
- [x] 最新文章列表(6 篇)
- [x] **Slogan 重写** — 参照 Dan Koe 的文案风格:
- 一句话价值主张(如 "The Art of..." / "How to..." 句式)
- 个人使命宣言
- 读者能获得什么(结果导向,而非信息罗列)
- [x] 视觉层级:标题 → slogan → 行动号召 → 文章列表
- [ ] Newsletter 订阅入口(可选)
### 关于页
- [x] 个人介绍 — 我是谁、做什么、为什么
- [ ] 社交链接 / 联系方式
### 内容
- [x] 5 篇文章(4 篇已发布,1 篇草稿)
### 技术优化
- [x] Google Fonts:Noto Sans SC
- [x] 自托管字体:iA Writer Quattro S
- [x] 导航栏底部阴影线已移除
- [ ] TTF 转 woff2 以提升加载性能
- [ ] 图片优化管线
- [ ] CI/CD 推送自动部署
- [ ] 访问统计
### SEO 与元数据
- [x] OpenGraph 已启用
- [x] Schema.org 结构化数据已启用
- [ ] 单篇文章自定义 meta(description、keywords)
- [ ] Sitemap 验证
- [ ] robots.txt 调优