Specific plugins per workspace

前端 未结 5 1712
感情败类
感情败类 2021-01-31 11:48

I came across this post and wondered if there is a way to activate only a few of all of my installed plugins depending on the workspace I currently work in.

For example

相关标签:
5条回答
  • 2021-01-31 12:07

    Although my solution won't let you install plugins per workspace but will solve the problem. The best way i found to do this is using different eclipse copies: Extract officialeclipse.zip to two different places and install plugins you like per eclipse.

    0 讨论(0)
  • 2021-01-31 12:08

    Maybe you can achieve your goal but it needs lots of "customization work" so I would not do it for myself :)

    • Create a "minimal" Eclipse install with plugins you use all of your workspaces.
    • Create one dropins folder for every workspace and put all of your "workspace-specific plugins" into that folder.
    • Create an Eclipse shortcut for all workspaces and use something like "-data _workspacedir_ -vmargs -Dorg.eclipse.equinox.p2.reconciler.dropins.directory=_dropindir_" in the shortcut.
    • Start eclipse with one of your new shortcuts.

    Note that in this case you cannot switch workspace within Eclipse, you have to close the current one and start the new one using the corresponding shortcut.

    UPDATE: I have found some Eclipse feature request for making this kind of setup easier if they will be implemented:

    • Software Update must allow to install plug-ins into extension location
    • Support for multiple bundle pools
    0 讨论(0)
  • 2021-01-31 12:15

    A bit late answer but if you want to manage many workspaces shortcut the following tool is very simple and helpful : http://www.xdreamteam.ch/downloads/eclipselauncher/

    I use it for sorting my projects by customers and workspaces, and it launch the right workspace with all the necessary configurations needed for each.

    0 讨论(0)
  • 2021-01-31 12:20

    Eclipse plugins are expected to start only as needed, in a lazy manner. I'm not saying that all behave exactly that way, but if you write your own plugin, you'll see this is how the technology works, your plugin gets called only as needed.

    So in Eclipse, if you configure your starting Perspective (Java for me) to have only the Views you need, the plugins that are used for other views should not be started. To do this, take the view away and save your perspective (Windows - Save perspective as).


    In addition, in Ganymede, in Windows - Preferences - General - Startup and Shutdown, there is a list of plugins that should be started on startup, so you can edit that list. I didn't try to see if this works per workspace though.

    0 讨论(0)
  • 2021-01-31 12:23

    You can use a different configuration folder for each Eclipse instance using the -configuration option when starting Eclipse.

    On Windows, I would use a batch file (e.g. run-eclipse.cmd) which looks a bit like this (a bit different on Unix, more complex on OS X because of the app packaging):

    eclipsec.exe -clean -configuration configs/%1/configuration
    

    Execute it with your environment ID (e.g. run-eclipse.cmd java). I use eclipsec because I need the console output, but you can use the plain eclipse.exe executable. The -clean is not mandatory either.

    Under my Eclipse installation folder, I will have a configs folder and under this folder I will have multiple configurations. Each config folder can have its' own plugins and folders. AFAIK, if you install plugins they will be installed in your configuration folder and not your main installation folder.

    The structure you get is like this:

    • Eclipse Folder
      • plugins
      • features
      • configs
        • java
          • plugins
          • features
          • configuration
    0 讨论(0)
提交回复
热议问题