I didn't know about @:, thanks!

It's a very handy thing, though in earlier versions of vim if you had a literal control+M in the last command-line (as entered with a control+V followed by control+M), it would truncate the command-line at that point rather than re-issue that last command-line. Other control-characters also caused similar problems.

There was also a second bug regarding commands that operate over a range. If you visually select a new range and use @: it would make the resulting command

        :'<,'>'<,'>command

which would choke vim.

There are workarounds for these older versions (if you need 'em, let me know and I'll elaborate).

However, since they have been fixed (I'm not sure whether it was in a late v6.x or only v7), it's an even more regular staple of my vim usage. However, it's just something to watch for if you use older versions of vim (such as what I have on some of my hosting providers that I can't easily upgrade myself).

-tim




Reply via email to