Git 命令速查

📦 基础命令

git init
初始化仓库
git clone <url>
克隆仓库
git status
查看状态
git add .
添加所有文件
git commit -m "message"
提交更改

🌿 分支操作

git branch
查看分支
git branch <name>
创建分支
git checkout <branch>
切换分支
git merge <branch>
合并分支

🚀 远程操作

git remote -v
查看远程仓库
git push origin <branch>
推送代码
git pull
拉取代码