git commit --amend --allow-empty
sau đó
git push origin master
Git nói rằng
! [rejected] master -> master (non-fast-forward)
error: failed to push some refs to 'remoteurl'
To prevent you from losing history, non-fast-forward updates were rejected
Merge the remote changes (e.g. 'git pull') before pushing again. See the
'Note about fast-forwards' section of 'git push --help' for details.
Tại sao? Làm thế nào để khắc phục điều này?