On Sat, Mar 27, 1999 at 09:58:37PM +0000, Alexander Koch wrote:
> Besides, what is the best way to have vi(m) load some kind
> of templates or even have macros asking you stuff? Does
> anyone of you have some ideas or pointers?
This is what I use:
" The File-Browser&Reader. Very handsome.
" The DAU mappings (read std.-texts)
map ,dau o~/.dau/"dddu__filelist
" start the file reader. Directory in register d.
map __filelist :split .
!!ls -l d
__LN-__mm
nn __LN- /[0-9] \K.. \=[0-9]<CR>3E2l
" crate mapping for enter
noremap __mm :map <CR> __rm0__LN-mai:r d`a"ay$:q!
@a
" remove mapping
noremap __rm :unmap <CR><CR>
This (at least on vim4.6) opens a new window with the contents of
'ls -l ~/.dau/' in it. You can then navigate to the correct line and
press enter to read the file at the current position. Start this with
,dau
But this is probably really off-topic...
CU,
Sec
--
Working on GUIs rots your brain.
The KDE and GNOME developers are prime examples. -- brandon in asr