今天我发现了--no-edit
for --amend
。但是,它导致我遇到以下问题。这里的步骤:
- git 克隆
- 对代码做了一些更改
- 混帐添加。
- git commit --amend --no-edit
git push 起源大师
! [rejected] master -> master (non-fast-forward) error: failed to push some refs to 'https://me@bitbucket.org/myRepo.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.
为什么?
注意:我是唯一一个在那个 repo 上工作的人。