git:推送到远程的正确语法

git:推送到远程的正确语法,git,Git,我只是尝试对一个远程分支进行强制推送,如下所示: $> git checkout myBranch $> git rebase origin/master $> git push --force origin/myBranch fatal: 'origin/myBranch' does not appear to be a git repository fatal: Could not read from remote repository. Please make sur

我只是尝试对一个远程分支进行强制推送,如下所示:

$> git checkout myBranch
$> git rebase origin/master
$> git push --force origin/myBranch

fatal: 'origin/myBranch' does not appear to be a git repository
fatal: Could not read from remote repository.

Please make sure you have the correct access rights
and the repository exists.
我知道我有分支遥控器(我一直都有正常的按钮),所以我猜
--force
origin/myBranch
有问题。有人能给我解释一下这里的正确语法吗?非常感谢

do:

git push --force origin myBranch
一般来说,它看起来是这样的

git push <remote> <sourceBranch>:<destBranch>
git推送:
如果源分支(本地分支中的分支)和目标分支(远程分支中的分支)的名称相同,则只需给出一个名称,git就会做正确的事情。

git push --force origin myBranch
一般来说,它看起来是这样的

git push <remote> <sourceBranch>:<destBranch>
git推送:
如果源分支(本地分支中的分支)和目标分支(远程分支中的分支)的名称相同,则只需给出一个名称,git就会做正确的事情。

git push --force origin myBranch
一般来说,它看起来是这样的

git push <remote> <sourceBranch>:<destBranch>
git推送:
如果源分支(本地分支中的分支)和目标分支(远程分支中的分支)的名称相同,则只需给出一个名称,git就会做正确的事情。

git push --force origin myBranch
一般来说,它看起来是这样的

git push <remote> <sourceBranch>:<destBranch>
git推送:

其中,如果源分支(本地分支中的分支)和目标分支(远程分支中的分支)的名称相同,您只需要给出一个名称,git就会做正确的事情。

要推送的第一个参数是
remote
。类似于read the fine的东西,要推送的第一个参数是
remote
。类似于read the fine的东西,要推送的第一个参数是
remote
remote
。类似于read the fine ok,因此在推送时不能使用执行重基时使用的
origin/master
语法。我想这很奇怪,所以当你做一个重基时使用的
origin/master
的语法不能在推的时候使用。我想这很奇怪,所以当你做一个重基时使用的
origin/master
的语法不能在推的时候使用。我想这很奇怪,所以当你做一个重基时使用的
origin/master
的语法不能在推的时候使用。我想这很奇怪