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

Re: Extending the Project Plugin

Expand Messages
  • Nathan Heijermans
    ... I also use the project plugin extensively. Have you used the in and out options in your .vimprojects file? From the documentation: in= and out= provide
    Message 1 of 4 , Aug 30, 2008
      > I make extensive use of the project plugin
      > (http://www.vim.org/scripts/script.php?script_id=69). I'm wondering
      > about whether it would be possible to extend this plugin so that there
      > are project-specific settings for each window that is created. For
      > example, I'd like to use setlocal to adjust makeprg, shellpipe and
      > maybe also do a couple of "let b:" commands at the same time. These
      > could then be held for that buffer and any commands (like :make) would
      > adjust to the project settings.
      >
      > Has anyone had any experience with the project plugin and if so, do
      > you think this would be straightforward? Any suggestions on a good
      > syntax for the .vimprojects file? Or is it just a really bad idea?!

      I also use the project plugin extensively. Have you used the 'in' and
      'out' options in your .vimprojects file? From the documentation:

      in= and out= provide the means to run arbitrary Vim scripts whenever you
      enter or leave a file's buffer (see the |BufEnter| and |BufLeave|
      autocommand events).

      A project entry would look like this:

      myproject=/path/to/project in=project_in.vim out=project_out.vim {
      ...
      }

      One thing I use this for is project-specific tags. For example, in
      'project_in.vim' file, I use 'set tags+=/path/to/project/tags' to set up
      appropriate tags files. You can also adjust your makeprg and shellpipe
      settings here. 'project_out.vim' can tear down any options that you set
      up in your 'project_in.vim'.

      Nathan



      --~--~---------~--~----~------------~-------~--~----~
      You received this message from the "vim_use" maillist.
      For more information, visit http://www.vim.org/maillist.php
      -~----------~----~----~----~------~----~------~--~---
    • A. S. Budden
      ... Thanks Nathan, I obviously missed this one in the documentation as I was looking for it under some slightly different terminology! That looks brilliant.
      Message 2 of 4 , Sep 11, 2008
        2008/8/30 Nathan Heijermans <nheijermans@...>:
        >
        >> I make extensive use of the project plugin
        >> (http://www.vim.org/scripts/script.php?script_id=69). I'm wondering
        >> about whether it would be possible to extend this plugin so that there
        >> are project-specific settings for each window that is created. For
        >> example, I'd like to use setlocal to adjust makeprg, shellpipe and
        >> maybe also do a couple of "let b:" commands at the same time. These
        >> could then be held for that buffer and any commands (like :make) would
        >> adjust to the project settings.
        >>
        >> Has anyone had any experience with the project plugin and if so, do
        >> you think this would be straightforward? Any suggestions on a good
        >> syntax for the .vimprojects file? Or is it just a really bad idea?!
        >
        > I also use the project plugin extensively. Have you used the 'in' and
        > 'out' options in your .vimprojects file? From the documentation:
        >
        > in= and out= provide the means to run arbitrary Vim scripts whenever you
        > enter or leave a file's buffer (see the |BufEnter| and |BufLeave|
        > autocommand events).
        >
        > A project entry would look like this:
        >
        > myproject=/path/to/project in=project_in.vim out=project_out.vim {
        > ...
        > }
        >
        > One thing I use this for is project-specific tags. For example, in
        > 'project_in.vim' file, I use 'set tags+=/path/to/project/tags' to set up
        > appropriate tags files. You can also adjust your makeprg and shellpipe
        > settings here. 'project_out.vim' can tear down any options that you set
        > up in your 'project_in.vim'.

        Thanks Nathan, I obviously missed this one in the documentation as I
        was looking for it under some slightly different terminology! That
        looks brilliant.

        Al

        --~--~---------~--~----~------------~-------~--~----~
        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.