git创建本地分支并提交到远程

2023-11-17 15:51:02 395

1.创建本地分支

git branch local_branch_name

 

2.切换到本地分支

git branch local_branch_name

 

3.提交代码

git add .

git commit -m "commit_message"

 

4.添加远程信息

git remote add origin remote_git_address

 

5.提交到远程

git push origin local_branch_name:remote_branch_name


提交成功!非常感谢您的反馈,我们会继续努力做到更好!

这条文档是否有帮助解决问题?

非常抱歉未能帮助到您。为了给您提供更好的服务,我们很需要您进一步的反馈信息:

在文档使用中是否遇到以下问题: