cream-vimabbrev : Convert Vim script command and option names between full and abbreviated forms
| script karma
Downloaded by 1105
Comments, bugs, improvements
script versions (upload new version)
*** WARNING! ***
This script is very much a work in progress and has several known bugs and likely many unknown ones. You will find little automatic success with it. It is being provided here for information only. Be hereby warned that using these functions will tear valid Vim script limb from limb leaving a trail of crying and gnashing of teeth behind.
That said, we would very much appreciate your feedback on correcting said anamolies. Feel free to forward suggestions or fixes to:
digitect (at) mindspring • com
This script is currently one half of a set of functions to convert Vim command and option names between short/abbreviated and long/full name forms. (Ex. "fu" => "function", "e" => "edit") These are sometimes indicated like "fu[nction]" or "e[dit]".
The script currently only converts from short to long. Based on my own preferences, I am less motivated to do the other side. ;) But I conceed it would be useful to have a polished routine to help going back and forth between the two for those with preferences for either readability or bandwidth conservation.
The script contains plenty of working debris at the bottom which shouldn't impact the code above. I have tried to be as complete as possible by using Vim's own syntax and option lists to compile the substitutions from. However you may notice omissions.
by Hari Krishna Dara, for the arrays of items to be substituted.
* Avoid mapping syntaxes.
* Avoid heinous "normal af|g^" => "normal af|global^" error
* Avoid heinous "normal j+r" => "normal j+read" error
* Add whitespace separators around evaluation operators and concatenation symbols.
This is one of many custom utilities and functions for gVim from the Cream project (http://cream.sourceforge.net), a configuration of Vim for those of us familiar with Apple and Windows software.
Just drop this file into your plugins directory, make sure you have the required dependencies (multvals.vim) also there, and start Vim. Then call the functions Cream_vimshort2long() and Cream_vimlong2short() from within the file to be converted.
Click on the package to download.
ip used for rating: 220.127.116.11