Exit Vim without committing changes in Git
git, git-commit, vim
Solution
To get git to not make a change when you are executing `git commit --amend` or `git rebase -i`.
Just delete the message (and save). All git does is look for a non empty message to see if a valid commit happened. Since there is a commit message (because you commited something before) git thinks that its a valid commit or rebase.
Problem
When I use `git commit --amend` or `git rebase -i`, vim opens up for me to make changes. If I then change my mind and exit vim without making any changes, a commit is still made which shows up in `git reflog`. How do I exit the editor without committing anything?