Jun 24, 2010 #1 paublo ISP Sep 14, 2006 127 US hi im looking for a way to have vim execute a command when :wq is used on a filename that is *.db. im looking to have named-checkzone executed when someone edits a zone file. tried a few things on /etc/vmrc autocmd VimLeave *.c /root/test.sh but nothing. thanks, Paul
hi im looking for a way to have vim execute a command when :wq is used on a filename that is *.db. im looking to have named-checkzone executed when someone edits a zone file. tried a few things on /etc/vmrc autocmd VimLeave *.c /root/test.sh but nothing. thanks, Paul
Jun 24, 2010 #2 Annihilannic MIS Jun 22, 2000 6,317 AU Are you sure your .vimrc is being processed at all? Why *.c rather than *.db? Annihilannic. Upvote 0 Downvote
Jun 24, 2010 #3 Annihilannic MIS Jun 22, 2000 6,317 AU I think the syntax you want is: Code: autocmd VimLeave *.db exe "!/root/test.sh" Annihilannic. Upvote 0 Downvote
Jun 28, 2010 Thread starter #4 paublo ISP Sep 14, 2006 127 US thanks for the reply! Upvote 0 Downvote