Git常用命令集合

见过不少人、经过不少事、也吃过不少苦,感悟世事无常、人心多变,靠着回忆将往事串珠成链,聊聊感情、谈谈发展,我慢慢写、你一点一点看......

git init <directory》`初始化本地仓库`
git add <file> `添加文件到暂存区`
git clone <url>`克隆一个远程仓库`
git reset <file>`从暂存区删除一个文件`
git commit -m "<message>" `提交更改`
git mv <currentpath> <newpath〉`移动或重命名文件`
git rm <file> `从存储库中删除文件`
git branch `显示分支`
git branch <branch> `创建一个分支`
git checkout <branch> `切换到—个分支`
git branch -d <branch> `删除一个分支`
git merge <branch> `合并分支`
git checkout <commit_id> `查看之前的提交`
git revert <commit_id> `恢复提交`
git reset <commit_id> `重置提交`
git status `查看存储库的状态`
git log `显示提交历史`
git diff `显示对未暂存文件的更改`
git diff <commit_ide1> <commit_id02> `显示两次提交之间的变化`
git stash list `列出存储`
git stash drop <stash id> `删除一个藏匿处`
git stash clear `删除所有藏匿处`
git stash pop <stashid> `应用和删除存储`
git remote add <remotename> <url> `添加远程仓库`
git stash show <stashid> `显示存储中的更改`
git remote remove <remotename> `删除远程仓库`
git remote `显示远程仓库`
git remote rename <old_name> <new_name> `重命名远程存储库`
git fetch <remotename> `从特定分支获取更改`
git pull <remote name> `从远程存储库中拉取更改`
git push <remotename> `将更改推送到远程存储库`
git push <remotename> <branch> `将更改推送到特定分支`

关注我,不失联。有啥问题请留言。

感情恋爱合集https://blog.csdn.net/forever8341/category_12863789.html

职业发展故事https://blog.csdn.net/forever8341/category_12863790.html

常用代码片段https://blog.csdn.net/forever8341/category_12863793.html

程序开发教程https://blog.csdn.net/forever8341/category_12863792.html

自我备考经验 https://blog.csdn.net/forever8341/category_12863791.html

高阶高效代码https://blog.csdn.net/forever8341/category_12873345.html

金融语言解析https://blog.csdn.net/forever8341/category_12877262.html

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

我曾经是个程序员

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值