企业🤖AI Agent构建引擎,智能编排和调试,一键部署,支持私有化部署方案 广告
> ### 分支 * 查看分支 `git branch` * 查看远程分支 `git branch -r` * 查看所有分支 `git branch -a` * 创建分支 `git branch <name>` * 切换分支 `git checkout <name>` * 创建+切换分支 `git checkout -b <name>` * 合并某分支到当前分支 `git merge <name>` * 删除分支 `git branch -d <name>` * 将本地新建的分支提交到远程仓库 ` git push origin new-branch` <br/> > ### 初始化并提交到远程仓库 * 本地工程git初始化 `git init` * 添加 `git add .` * 提交到本地仓库 `git commit -m "first commit"` * 设置远程仓库 `git remote add origin git@github.com:asdj07/xxx.git` * 推送到远程仓库 `git push -u origin master` <br/> > ### 从远程仓库更新到本地 `git fetch` * 默认取回所有分支的更新 `git fetch origin`