常用命令备忘
本地的当前文件夹为 ~/jekyll/zhaotong2027.GitHub.io/_posts
同一时期只能有一篇文章正在编辑或一个问题正在解决,相关子文件夹是代办和已经编辑结束的文章。
本页用来写一些常用命令备忘,避免长期不动博客,基本位置和命令想不起来的尴尬情况。
常用命令:
| jekyll clean | 清除缓存 |
|---|---|
| jekyll build | 生成静态网页 |
| jekyll server | 打开本地服务器 http://localhost:4000/ |
| git clone | 本地初次拉取代码 |
|---|---|
| git pull | 更新 |
| git status | 当前状态 |
| git add . | 添加所有改动代码 |
| git commit -am “” | 提交并添加注释 |
| git push | 本地提交推到远程 |
| git rm –cached a.a | 移除文件(只从缓存区中删除) |
git clone git@github_zhaotong.com:zhaotong2027/zhaotong2027.GitHub.io.git