Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add ZQ to quit without saving #1

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Conversation

xfnw
Copy link

@xfnw xfnw commented Jan 16, 2021

ZZ or :wq quits and saves, but there is no key combination for :q! quit without saving. this pr adds vim's ZQ key combination to quit without saving.

i know a lot of vi implimentations do not have this, but it is nice to have and is not very big.

@brentr
Copy link
Owner

brentr commented Jan 16, 2021

Your patch looks fine... however...
The ZQ sequence discards all changes without feedback to the user.
I completely understand why the original author this vi clone choose to omit it.
With the :q! sequence, you can see the keystrokes on the command line as you type them.
Granted, it is two more keystrokes. I'm OK with that to avoid the prospect of losing hours of work.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants