From d94a9346215294a2f5258a110fb1c2c6443530f2 Mon Sep 17 00:00:00 2001 From: Simon Ruderich Date: Sat, 28 Feb 2009 17:27:43 +0100 Subject: [PATCH] zsh: Prevent :q exists the shell. This happens if I confuse the shell with Vim. --- zsh/rc | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/zsh/rc b/zsh/rc index e49885e..0724afc 100644 --- a/zsh/rc +++ b/zsh/rc @@ -265,8 +265,9 @@ alias m='mutt' alias v='vim' alias vi='vim' -# Exit binding like in Vim; I sometimes confuse editor and shell. -alias :q='exit' +# I sometimes confuse editor and shell, print a warning to prevent I exit the +# shell. +alias :q='echo "This is not Vim!" >&2' # Edit the mercurial patch queue series file for the current mercurial # repository in Vim. Also change Vim's pwd to the patches directory so other -- 2.45.2