直前のcommitを修正
$ git commit --amend
pushしてしまったcommitを修正
$ git push ! [rejected] master -> master (non-fast-forward) 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. $ git push origin +master Counting objects: 5, done. Delta compression using up to 4 threads. + 40933f6...91621ef master -> master (forced update)
参考
http://d.hatena.ne.jp/mrgoofy33/20100910/1284069468
http://pandazx.hatenablog.com/entry/2012/10/14/005716
コミット時に--amendと--authorを指定
git commit --amend -m "test test test" --author="my_new_name <new_name@example.com>"
めも