+++ date = "2017-04-05" tags = ["git"] title = "git fixup" slug = "git" +++ `git fixup`が便利だった件。 こちらは`commit fixup`でrebaseを書き換える場合 ``` $ GIT_SEQUENCE_EDITOR="sed -ie '2 s/pick/fixup/g'" git rebase -i --root ``` こうやると1行目のコミットに2行目のコミットが統合される。 あと、`~/.gitconfig`に書いておくのも便利そう(上記とは内容が異なる)。 > ~/.gitconfig ```bash [rebase] autofixup = true autosquash = true ```