I would like to run :helptags ~/.vim/doc in vim, but from command line.

The purpose is to run the command occasionally with other commands to keep my tools up-to-date (probably in a cron job on my development machine.

I looked around man vim, but cannot figure out what option I need to pass.

I think this is a general question for vim, but I'm using Mac and Ubuntu for the development.

link|improve this question

feedback

1 Answer

up vote 1 down vote accepted

From the vim(1) man page:

   +{command}

   -c {command}
               {command}  will  be  executed after the first file has been
               read.  {command} is interpreted as an Ex command.   If  the
               {command}  contains  spaces  it  must be enclosed in double
               quotes (this depends on the shell that is used).   Example:
               Vim "+set si" main.c
               Note: You can use up to 10 "+" or "-c" commands.

     ...

   --cmd {command}
               Like using "-c", but the command is  executed  just  before
               processing  any  vimrc file.  You can use up to 10 of these
               commands, independently from "-c" commands.

Just put :q! as the final command if you want to get back out.

link|improve this answer
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.