I wrote two small functions (rebuilding a cscope database and the tags), and created a mapping for them to execute at the same time, however when I execute the mapping I get an error E488 and the first command is not executed. Here is what I have in my vimrc
function! RebuildCscope(cscope_files, cscope_out, dir_list)
" Kill all csope connections
exe 'silent cs kill -1'
" Build a file list
silent call BuildFileList(a:cscope_files, a:dir_list, '*.[ch]', 1)
" Rebuild the database.
silent call BuildCscopeDb(a:cscope_files, a:cscope_out)
" Add a csope connections
exe 'silent cs add '.a:cscope_out
endfunction
function! RebuildCtags(ctags_files, ctags_out, dir_list)
" Build a file list
silent call BuildFileList(a:ctags_files, a:dir_list, '*.[ch]', 0)
" Build the database
silent call BuildCtagsDb(a:ctags_files, a:ctags_out)
endfunction
nnoremap <silent><F7> :call RebuildCscope(g:cscope_files, g:cscope_out, g:src_dirs)<cr> | :call RebuildCtags(g:ctags_files, g:ctags_out, g:src_dirs)<cr>
It does execute the second function (RebuildCtags), but does not execute the first one. Does anybody know what is it I'm doing wrong?
Any help is appreciated.
--
--
You received this message from the "vim_use" maillist.
Do not top-post! Type your reply below the text you are replying to.
For more information, visit http://www.vim.org/maillist.php
---
You received this message because you are subscribed to the Google Groups "vim_use" group.
To unsubscribe from this group and stop receiving emails from it, send an email to vim_use+unsubscribe@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
Friday, June 7, 2013
Subscribe to:
Post Comments (Atom)
No comments:
Post a Comment