一分钟用Hexo建博客

这篇教程的前提是你有npm和git,另外我已经在github上创建好了一个github pages项目。下面开始:

安装

npm install -g hexo-cli
hexo init marvinxu.github.io
cd marvinxu.github.io
npm install
npm install hexo-deployer-git --save

修改根目录下的 _config.yml

deploy:
  type: git
  repo: https://github.com/MarvinXu/marvinxu.github.io.git
  branch: master

部署

hexo deploy

访问 http://marvinxu.github.io/,成功~

切换主题

下载

git clone https://github.com/iissnan/hexo-theme-next themes/next

修改项目配置文件_config.yml,使用主题

theme: next

部署

hexo deploy

成功啦~ 看一下结果:

2101e7db-7429-45d7-8912-13fa1f6fdab3.png

参考文章:

Hexo系列:(一)Hexo+GitHub pages搭建个人博客
NexT 开始使用
segmentfault markdown

最后编辑于
©著作权归作者所有,转载或内容合作请联系作者
平台声明:文章内容(如有图片或视频亦包括在内)由作者上传并发布,文章内容仅代表作者本人观点,简书系信息发布平台,仅提供信息存储服务。

推荐阅读更多精彩内容