Loading ...
Sorry, an error occurred while loading the content.

Re: how to use string variable for "cs add" command

Expand Messages
  • Tony Mechelynck
    ... and since :exe[cute] accepts any number of arguments (and concatenates them space-separated), ... would work just as well. -- You received this message
    Message 1 of 9 , Feb 1, 2010
    • 0 Attachment
      On 29/01/10 04:23, pansz wrote:
      > Ni, Ruiyu 写道:
      >> Hi,
      >> How can I make the following command pass VIM check in _vimrc file?
      >>
      >> let CodeRoot = "E:/code"
      >> let CscopeDb = CodeRoot . "/cscope.out"
      >> cs add CscopeDb CodeRoot
      >>
      >>
      >> the problem is in line 3, cs add only accept direct string but not the
      >> variable. For example if I use the following cs add command VIM is fine.
      >> Cs add E:/code/cscope.out E:/code
      >>
      >> Thanks,
      >> Ray
      >>
      >
      > what about
      >
      > :exe "cs add ".ScsopeDb." ".CodeRoot
      >
      >
      > ?
      >

      and since ":exe[cute]" accepts any number of arguments (and concatenates
      them space-separated),

      :exe 'cs add' CscopeDB CodeRoot

      would work just as well.

      --
      You received this message from the "vim_use" maillist.
      For more information, visit http://www.vim.org/maillist.php
    • pansz
      ... Nice hint! -- You received this message from the vim_use maillist. For more information, visit http://www.vim.org/maillist.php
      Message 2 of 9 , Feb 3, 2010
      • 0 Attachment
        > and since ":exe[cute]" accepts any number of arguments (and concatenates
        > them space-separated),
        >
        > :exe 'cs add' CscopeDB CodeRoot
        >
        > would work just as well.
        >

        Nice hint!

        --
        You received this message from the "vim_use" maillist.
        For more information, visit http://www.vim.org/maillist.php
      Your message has been successfully submitted and would be delivered to recipients shortly.