hugo-theme-stack setting for github

environment

txt 复制代码
To install Hugo on Kali Linux 2023.1, there are a few options available, depending on your preference. Here are two methods:
  • Method 1: Install using the APT package manager. Open a terminal and run the following command:

download hugo

shell 复制代码
# kali/debian
sudo apt install hugo
hugo version # 查看版本

# yum
sudo yum install hugo -y

# arch
sudo pacman -S hugo
# 选择主题进行下载  也可手动下载
git submodule add https://github.com/CaiJimmy/hugo-theme-stack/ themes/hugo-theme-stack

download git

shell 复制代码
# kali自带 预装
# yum/redhat系
sudo yum install git
# arch
sudo pacman -Syu git
# debian
sudo pacman -Syu git

可恶的windows

安装Hugo

https://gohugo.io/getting-started/installing/#less-technical-users

安装Git

shell 复制代码
winget install Git.Git

建站

1 log in or sign in

github

2 在github账户中创建一个项目 名为 你的Github用户名.github.io

  • 这是存放生成出来的网站文件的地方

3在本地搭建网站

shell 复制代码
hugo new site  test  # 你的网站的根目录名
cd test/theme
git clone # 你的主题的GitHub网址.git  # wait a long time!

Stack的文档

stack网站目录结构

复制代码
├── archetypes                  
│   └── default.md
├── config.yaml                 # 网站配置文件
├── content                     # 站点内的内容都在这里
│   ├── categories              # "分类"页面的首页
│   │   └── Test                # "分类"页面下的一个分类页面
│   ├── page                    # 显示在网站主页左侧边栏菜单的选项
│   │   ├── about               # 左侧边栏菜单中的"关于"页面
│   │   ├── archives            # 左侧边栏菜单中的"归档"页面
│   │   ├── links               # 左侧边栏菜单中的"链接"页面
│   │   └── search              # 左侧边栏菜单中的"搜索"页面
│   └── post                    # 用户写的帖子都放在这里,每个子文件夹对应一个帖子
│       ├── chinese-test
│       ├── emoji-support
│       ├── markdown-syntax
│       ├── math-typesetting
│       ├── placeholder-text
│       └── rich-content
├── data
├── layouts
├── LICENSE
├── README.md
├── resources
│   └── _gen
│       ├── assets
│       └── images
├── static                     # 放用户自定义字体、用户头像、网站小图标等
└── themes                     # 放各种主题
    └── hugo-theme-stack       # stack主题
        ├── archetypes
        ├── assets
        ├── config.yaml
        ├── data
        ├── debug.sh
        ├── exampleSite
        ├── go.mod
        ├── i18n
        ├── images
        ├── layouts
        ├── LICENSE
        ├── netlify.toml
        ├── README.md
        └── theme.toml

配置

  • 把你的网站名/themes/hugo-theme-stack/exampleSite/目录下的config.yaml复制到网站根目录(也就是你的网站名这个目录)
  • 删除网站根目录的config.toml
  • 然后打开网站根目录下的config.yaml进行填空
  • 博主头像放在/themes/hugo-theme-stack/assets/img/下 关于那个头像下的emoji,如果你不想加上,emoji那一行留空就好
相关推荐
zhensherlock3 小时前
Protocol Launcher 系列:Trello 看板管理的协议自动化
前端·javascript·typescript·node.js·自动化·github·js
FEF前端团队8 小时前
开发知识库 #01:Git 全面操作教程
git·github
栩栩云生8 小时前
x-cmd v0.8.15: claw AI 助手升级,连微信、飞书更稳了;free 新增专家模式,直接把底层内存细节喂给你
github·agent·命令行
傻啦嘿哟10 小时前
Python 文件批量处理:重命名/备份/同步运维实战指南
linux·数据库·github
淘矿人10 小时前
Claude辅助算法设计与优化
人工智能·python·算法·microsoft·github·bug·pygame
逛逛GitHub10 小时前
给 10 万 Star 的 Hermes 装个记忆外挂,AI 终于能越用越聪明了。
github
王莎莎-MinerU11 小时前
MinerU 生态全接入:LangChain、Dify、RAGFlow、LlamaIndex 六大框架完整集成指南(2026)
计算机视觉·chatgpt·langchain·pdf·github·aigc
神一样的老师14 小时前
【兆易创新GD32VW553开发板试用】 BSP 从 GitHub 下载与编译指南
单片机·github·rt-thread
DevilSeagull15 小时前
MySQL(1) 安装与配置
java·数据库·git·mysql·http·开源·github
kefon15 小时前
从零搭一个 AI Agent:我选了最省钱的方案
开源·github·agent