:cabbrev e E

Now ":e" will change itself to ":E" when not followed by a letter, but ":edit" will get you the "old" behaviour of the :e
 command.

However, beware the funky behaviors that can ensue from this:

Trying to type something like

        :echo "the letter e is nice"

will expand to

        :echo "the letter E is nice"

There are other oddball places this has manifested itself for me
in the past (when trying similar things).

Yakov's solution (that came in while typing this) has some checks
in place to solve that.  However, I think Yakov's solution just
works in Vim7 and isn't backwards compat. with 6.x and earlier
(for those of us with hosted servers that are a little sluggish
in upgrading).

-tim








Reply via email to