Welcome to Hexo! This is your very first post. Check documentation for more info. If you get any problems when using Hexo, you can find the answer in troubleshooting or you can ask me on GitHub.

Quick Start

创建一个新发布 Create a new post

1
$ hexo new "My New Post"

More info: Writing

启动服务 Run server

1
2
$ hexo server
$ hexo s && hexo g

More info: Server

生成静态文件 Generate static files

1
2
$ hexo generate
$ hexo s && hexo g

More info: Generating

部署到远程仓库 Deploy to remote sites

1
2
$ hexo deploy
$ hexo g -d

重新部署恢复 Hexo

1
npm install hexo-cli -g
  • 保留_config.yml,theme/,source/,scaffolds/,package.json,.gitignore,gulpfile.js 这些项目在目录下Git bash
1
2
3
4
npm install
npm install hexo-deployer-git --save
npm-check -u
hexo clean && hexo g && hexo s

查看是否本地可以运行Hexo,网站正常后可以发布到远程仓库

1
hexo d

More info: Deployment