Initialize with a command link GitHub
Need to link to GitHub with SSH public key, note that you cannot copy directly from Vim
introducing a command : Xsel < Test.txt
Copy the contents of a file directly into the Clipboard
Specific practices
git remote add pprp www.github.com/namessh-keygen -t rsa -C "[email protected]"xsel < /home/name/.ssh/id_rsa.pub
Specific applications added to remote libraries
git remote add origin//添加远程仓库 [email protected]:pprp/deeplearning.gitgit push -u origin master
Generate Ssh-key:
ssh-keygen -t rsa -C "[email protected]"
Verify success:
ssh -T [email protected]
Local Update Remote modification
git fetch origin
To synchronize updates to a local:
git merge origin/master
New File Upload later
git add newfilenamegit commit -m "message"git push origin master
Add Delete Branch
git remote -v 查看git remote add name [email protected]:pprp/deeplearning.gitgit remote rm name
Clone library file
git clonegit clone http://github.com/pprp/nameofrepo
Can not add
git commit -am 'message'
View commit History
git loggit log --oneline 简洁版
Branching operations
git branch newnameforbranchgit checkout newnameforbranchgit branch -d newnameforbranch 删除
Linux under command link GitHub