hexo-next-blog简易搭建
环境配置(archlinux)
1 | sudo pacman -S nodejs npm |
hexo init在你想要创建的文件夹下初始化
npm install hexo-theme-next根目录下下载next主题
touch _config.next.yml 创建next的配置文件
cp node_modules/hexo-theme-next/_config.yml _config.next.yml 复制默认配置
修改_config.yml下的theme为next
hexo clean清除缓存
主题配置
修改主题为scheme: Pisces
添加menu
1 | menu: |
配置分类
hexo new page categories
1 | --- |
文章头添加以分类
1 | categories: |
配置标签
hexo new page tags
同样
1 | --- |
文章头添加以标签
1 | tags: |
上传GitHub(由于以前有一个github page,可能步骤不全)
下载插件npm install hexo-deployer-git --save
编辑站点配置文件 _config.yml
1 | deploy: |
在设置中修改page为静态构建,重新发布page就行
注意文章头最好有摘要,这样首页不会展示全文
例如
1 | description: "hexo-next-blog环境搭建,github page部署" |