私のローカルdevelop
ブランチをいくつかのコミットにリセットし、ローカルのdevelop
ブランチをリモートにプッシュしたいので、リモートのHEADもまたわずかなコミットにリセットされます。言い換えればリモートブランチをいくつかのコミットにハードリセットします
、私はそうのようでした:
UserName path/ (develop)
$ git reset --hard {CommitIdOfAFewCommitsBehind}
Your branch is behind 'origin/develop' by 14 commits, and can be fast-forwarded.
(use "git pull" to update your local branch)
nothing to commit, working tree clean
$ git push origin develop
To https://github.devtools.merrillcorp.com/Javelin/wopi-poc.git
! [rejected] develop -> develop (non-fast-forward)
error: failed to push some refs to 'https://github/repo.git'
hint: Updates were rejected because the tip of your current branch is behind
hint: its remote counterpart. Integrate the remote changes (e.g.
hint: 'git pull ...') before pushing again.
hint: See the 'Note about fast-forwards' in 'git push --help' for details.
は、どのように私は、リモートでも、私が欲しいコミットIDに行かせるのですか?
緑色のチェッカーに9分。 –