# knowledge **Repository Path**: yanxxit/knowledge ## Basic Information - **Project Name**: knowledge - **Description**: Knowledge 个人知识库博客 - **Primary Language**: JavaScript - **License**: Not specified - **Default Branch**: main - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2025-10-09 - **Last Updated**: 2026-08-01 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README # knowledge 个人知识库 ## 使用AI生成的知识库记录个人学习和工作中的知识 1. 避免反复创建 ## 目录 ```sh . ├── archetypes ├── config.toml # 配置文件 ├── config/* # 配置文件 ├── content # 内容区域 ├── data ├── layouts # 布局 ├── i18n # 多语言 ├── static # 静态目录 └── themes # 主题 ``` ## 基本使用 ### 生成基础站点 ```sh hugo new site my-project ``` 下载一个主题。可以在 https://themes.gohugo.io/ 找到更多你喜欢的主题。 ```sh cd my-project git init git submodule add https://ghproxy.com/https://github.com/budparr/gohugo-theme-ananke.git themes/ananke git submodule add https://ghproxy.com/https://github.com/thegeeklab/hugo-geekdoc.git themes/hugo-geekdoc ``` ### 创建文章 创建一个 about 页面: ```sh $ hugo new about.md # about.md 自动生成到了 content/about.md ,打开 about.md 看下: # 创建第一篇文章,放到 post 目录,方便之后生成聚合页面。 $ hugo new post/first.md $ hugo new post/docker/docker.md --config config/hugo-theme-cleanwhite.toml $ hugo new post/terminal/tools.md --config config/hugo-theme-cleanwhite.toml $ hugo new post/go/golang.md --config config/hugo-theme-cleanwhite.toml ``` 它看上去应该像这样: ```md --- title: "My First Post" date: 2021-03-10T18:37:11+08:00 draft: true --- Hello World! ``` 可以在这里给文章添加添加更多属性配置(标签,描述,类别,作者)。 可以在 https://gohugo.io/content-management/front-matter/ 了解更多的配置项。 ### 编译 ```sh hugo --config config/hugo-theme-cleanwhite.toml ``` ### 启动服务 ```sh hugo server --config config/hugo-theme-cleanwhite.toml ``` ## theme 主题 ### themes/hugo-theme-cleanwhite - 支持plantuml - 不支持gist - 搜索功能第三方提供,需要集成 ```sh git clone https://github.com/zhaohuabing/hugo-theme-cleanwhite.git themes/hugo-theme-cleanwhite # 配置hugo-theme-cleanwhite.toml hugo server --config config/hugo-theme-cleanwhite.toml ``` ### themes/hugo-geekdoc - 嵌入 gist - 部分图片 - 不支持plantuml - 可搜索标题 ```sh git clone https://github.com/thegeeklab/hugo-geekdoc.git themes/hugo-geekdoc cd themes/hugo-geekdoc npm install npm run build # hugo-geekdoc.toml hugo server --config config/hugo-geekdoc.toml ``` ### themes/hugo-whisper-theme - [x] 没成功 ```sh git clone https://github.com/zerostaticthemes/hugo-whisper-theme.git themes/hugo-whisper-theme # 配置hugo-whisper-theme.toml hugo server --config config/hugo-whisper-theme.toml ``` ### hugo-book 比较麻烦 https://themes.gohugo.io/themes/hugo-book/ ### 其他模块 - OK