function! ShowFunc()
let oldmake= &makeprg
let &makeprg= 'listfunc'
silent! make%
cwindow
let &makeprg=oldmake
endfunc
"To enable restoring (for an xterm):
"set t_ti=^[7^[[r^[[?47h t_te=^[[?47l^[8
"(Where ^[ is an
set t_ti=^[7^[[r^[[?47h
set t_te=^[[?47l^[8
set ignorecase
"map
"map
"set wmh=0
map ^[j
map ^[k
map
map
map
map
map
map
augroup filetypedetect
au! BufRead,BufNewFile *.inc setfiletype make
augroup END
" Automatically reload .vimrc when changing
autocmd! bufwritepost .vimrc source %
============================
The listfunc script:
#!/bin/sh
ctags -x --c-types=f -u $1 | gawk '{printf("%s:%s: %s\n",$4,$3,$1) > "/dev/stderr"}'
No comments:
Post a Comment