首页 > 其他 > 详细

git总结

时间:2019-01-25 19:48:48      阅读:178      评论:0      收藏:0      [点我收藏+]

git客户端配置

cd ~

git config --global user.name "<USERNAME>"

git config --global user.email "<EMAIL>"

ssh-keygen -t rsa -C "68297@sangfor.com" -b 4096

cat ~/.ssh/id_rsa.pub

 

git使用

git clone <URL> ./

 

git remote [-v]

git remote show origin

git branch [-a]

 

git checkout -b <BRANCH_NAME> origin/<BRANCH_NAME>

 

git branch <NEW_COPY_BRANCH_NAME>

git chekcout <NEW_COPY_BRANCH_NAME>

git push origin <NEW_COPY_BRANCH_NAME>

git branch -u origin/<NEW_COPY_BRANCH_NAME>

 

git branch -vvv

 

git branch -d <BRANCH_NAME>

git push origin -d <BRANCH_NAME>

 

git branch -a

git remote prune origin

 

git pull

git fetch origin

git merge <BRANCH_NAME>

git status

git add <FILE_NAMEs>

git commit -m "COMMIT_MESSAGE"

git log

git push

 

git reset --hard

 

 

git总结

原文:https://www.cnblogs.com/RongjiJin/p/10321296.html

(0)
(0)
   
举报
评论 一句话评论(0
关于我们 - 联系我们 - 留言反馈 - 联系我们:wmxa8@hotmail.com
© 2014 bubuko.com 版权所有
打开技术之扣,分享程序人生!