Yanjie's Blog

这个博客已通过认证

Hugo 博客搭建记录

📅 | 🏷️ , , ,
文章目录

博客迁移到 Hugo 了~

本文简要说明了本博客的建站流程,时间久了容易遗忘,在这里记录一下,希望也能对大家有所帮助。

安装 Hugo 和 Github Desktop

brew install hugo

安装 Github Desktop,并连接仓库

创建博客

hugo new site my-blog
cd my-blog

添加主题

git submodule add https://github.com/yuanji-dev/futu.git themes/futu
git submodule add https://github.com/martignoni/hugo-notice.git themes/hugo-notice

配置 hugo.toml 和其他博客相关文件

参考 nikkiYuanji’s Blog

Cloudflare pages 部署

参考 Windows 下使用 Hugo 和 Cloudflare Pages 配置博客

Github Action 自动部署

参考 nikki.github 目录下的文件

其他问题

常用 Hugo 命令

hugo new posts/article.md   # 创建新博文
hugo server -D -w           # 启动服务器,在本地预览网站

待解决问题