Know when you will type :q in your term instead of vi(m), the alias will chewed you out.

2009-12-20 46 words 1 min read

most simple solution is to alias :q like so:
alias :q=`echo ”This is not vim”`

but as someone suggested in commandlinefu, you can use tput to put some color and fun into this.
alias :q=’tput setaf 1; echo >&2 ”this is NOT vi(m) :/”; tput sgr0’


Tags: Alias bash vi vim

author

Authored By Amit Agarwal

Amit Agarwal, Linux and Photography are my hobbies.Creative Commons Attribution 4.0 International License.

We notice you're using an adblocker. If you like our webite please keep us running by whitelisting this site in your ad blocker. We’re serving quality, related ads only. Thank you!

I've whitelisted your website.

Not now
This website uses cookies to ensure you get the best experience on our website. Learn more Got it