配置参数:
1 | git config --global user.name "alpha" |
创建版本库
1 | cd d: |
提交文件
1 | git add readme.txt (将某个文件添加到暂存区) |
从GitHub更新文件到本地
1 | $ git clone https://github.com/alpha-huang/alpha.git (下载代码到本地) |
修改文件
1 | git add . (添加到暂存区) |
放弃本地修改 强制更新1
2git fetch --all
git reset --hard origin/master
hexo源文章维护常用命令1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19cd alpha-huang-blog
npm install hexo-cli
hexo init
npm install --save hexo-admin
git init
git remote add origin https://github.com/alpha-huang/hexo-source
git fetch
git reset --hard origin/master
rm source/_posts/hello-world.md
rm -r themes/landscape
hexo g
hexo s
npm install hexo-deployer-git
git add .
git commit -m "hexo config and source"
git status
git push -u origin master
git使用简易指南 http://www.bootcss.com/p/git-guide/