我需要学习如何将本地分支推送到远程分支,麻烦看下面的内容。非常感谢帮助!
本地分支是在克隆仓库后执行以下操作创建的:
$ git checkout -b mybranch remotes/origin/mybranch
$ git branch -a
master
* mybranch
remotes/origin/HEAD -> origin/master
remotes/origin/master
remotes/origin/mybranch
但是当尝试将更改推回服务器时:
$ git push mybranch mybranch
fatal: 'mybranch' does not appear to be a git repository
fatal: The remote end hung up unexpectedly
$ git push remotes/origin/mybranch mybranch
fatal: 'mybranch' does not appear to be a git repository
fatal: The remote end hung up unexpectedly
$ git push origin/mybranch mybranch
fatal: 'mybranch' does not appear to be a git repository
fatal: The remote end hung up unexpectedly