安装Hexo命令到系统
1 | $ npm install hexo-cli -g |
初始化
1 | $ hexo init |
安装modules
1 | $ npm install |
创建文章
1 | hexo new name |
创建页面名
1 | hexo new page name |
生成页面
1 | $ hexo g # hexo generate |
启动本地服务
1 | $ hexo s # hexo server |
浏览器查看
1 | $ open http://localhost:4000 |
修改主题
1 | $ git clone https://github.com/litten/hexo-theme-yilia.git themes/yilia |
获取到主题后,修改_config.yml文件中theme的属性设置为yilia即可
运行命令重新生成页面
1 | $ hexo g |
deploy
安装hexo部署到github辅助工具
1 | npm install hexo-deployer-git --save |
修改根目录下的_config.yml文件
1 | deploy: |