Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

huh. I'm using ZZ all the time, but I thought it is :wq


It's possible it was at some point, but my local copy of vim tells me it is 'same as ":x"' in `:help ZZ`


You never accidentally used it on an unnamed buffer?


unnamed as [No Name]? both :wq and ZZ (:x) do the same: "E32: No file name"


Sorry, unnamed AND unmodified. My bad.

And actual advantage here is that `ZZ` can be your "quietly quit anything" key. It'll close quickfix, locationlist, previewwindow, etc without complaining.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: