Date: Mon, 15 Jun 2009 13:00:30 -0700 From: Gary Kline <kline@thought.org> To: FreeBSD Questions <freebsd-questions@FreeBSD.ORG> Subject: Re: vim question... Message-ID: <20090615200030.GA37102@thought.org> In-Reply-To: <20090615045106.GA56586@kokopelli.hydra> References: <20090615024643.GA33420@thought.org> <C65B19B2.7D4BB%mksmith@adhost.com> <20090615045106.GA56586@kokopelli.hydra>
next in thread | previous in thread | raw e-mail | index | archive | help
On Sun, Jun 14, 2009 at 10:51:06PM -0600, Chad Perrin wrote: > On Sun, Jun 14, 2009 at 09:18:42PM -0700, Michael K. Smith wrote: > > On 6/14/09 7:46 PM, "Gary Kline" <kline@thought.org> wrote: > > > > > > the main reason i don't use vim is because of its [u]ndo > > > command. as most of you can understand, there are a whole slew > > > of times when i need to undo something. too often in vim, > > > hitting 'u' --- sometimes > once accidentally --- has resulted in > > > a small disaster. [[i have too many current/recent copies of > > > my working files to do TOO much damage!]] Anyway, is there a > > > means of setting the undo key to mimic vi/nvi? > > > > > If you undo something and it was a mistake, just use the period (.). > > It's probably better to get in the habit of using :redo than the period > to undo an undo, since :redo (or :red for not-very-short) can advance > through several levels of undos, but the period can only repeat one > single thing over and over again. If you're six levels back in undos, > and you want to undo all six levels, but you use the period once, I think > that'd wipe out all those levels of undo so they aren't recoverable. Yeah, see, this is exactly my problem. UAually, i just hit 'u' once, check my code, continue. But then I think there may be cap-u ['U'] ... or maybe not. It's only happened three or four times, but that was enough to keep me away from vim! You say that :red can undo 'several' levels.... without having me dig thru the vim docs, does :reo take an arg, like maybe :redo 5 ? bleah. bill joy had the better idea back in the late 70's with the original vi [IMHO] :_) > > I haven't directly tested that recently, but that's how I recall it > working back when I first learned about multiple undo/redo levels for > Vim, lo these many moons ago when the world was young and dinosaurs > roamed the Earth. man, i hear THAT! > > -- > Chad Perrin [ original content licensed OWL: http://owl.apotheon.org ] > Quoth H. L. Mencken: "Democracy is the theory that the common people > know what they want and deserve to get it good and hard." -- Gary Kline kline@thought.org http://www.thought.org Public Service Unix http://jottings.thought.org http://transfinite.thought.org For FBSD list: http://transfinite.thought.org/slicejourney.php The 4.98a release of Jottings: http://jottings.thought.org/index.php
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20090615200030.GA37102>