buzhidao buzhidao - 1 year ago 76
Git Question

git commit -m won't involk vim to edit

I can use

git commit -a
to commit a message and it open vim to edit. However this command automatically commit everything that has been modified. I would really like to use `git commit -m' to commit. However this command won't invoke vim editor. How to solve this issue.

Answer Source

This option seems to be just what you're looking for:

   -e, --edit
       The message taken from file with -F, command line with -m, and from
       commit object with -C are usually used as the commit log message
       unmodified. This option lets you further edit the message taken
       from these sources.
Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download