Skip to content
This repository has been archived by the owner on Nov 30, 2021. It is now read-only.

Use BufDelete or similar instead of BufWritePost in :GitCommit #7

Closed
wincent opened this issue May 20, 2009 · 2 comments
Closed

Use BufDelete or similar instead of BufWritePost in :GitCommit #7

wincent opened this issue May 20, 2009 · 2 comments

Comments

@wincent
Copy link

wincent commented May 20, 2009

When writing a lengthy commit message you might want to save the buffer occasionally out of habit, but if you do you'll find that a commit takes place and your half-written commit message got included.

To avoid this, I think it would be a good idea if the BufWritePost autocmd in the :GitCommit implementation were changed to BufDelete or similar.

It would also match the behaviour of the command line when you have EDITOR=vim (or any other editor) in your environment and do a "git commit": the actual commit is only processed when you exit the editor, not when you save the message.

@wincent
Copy link
Author

wincent commented May 20, 2009

If you want to cherry pick, the suggested change is here:

wincent/git-vim@a5a8264bf1bb90ae80732b877708c9d5097b1d9c

@wincent
Copy link
Author

wincent commented May 20, 2009

@wincent wincent closed this as completed Jun 18, 2016
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant