可以同时打开多个 Eclipse 实例吗?

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/2351806/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-09-19 14:28:00  来源:igfitidea点击:

Possible to have several instances of Eclipse open simultaneously?

javaeclipse

提问by devoured elysium

I'd like to know if it's possible to have several instances of Eclipse open at the same time. I'm using it for Java development. I know I can have several files from different projects open at the same time (at least that's what it seems to me), but whenever I try to open a second instance it shows me the following message:

我想知道是否可以同时打开多个 Eclipse 实例。我将它用于 Java 开发。我知道我可以同时打开来自不同项目的多个文件(至少在我看来是这样),但是每当我尝试打开第二个实例时,它都会向我显示以下消息:

alt text http://img46.imageshack.us/img46/5033/sxbz3mti34afybrafhc32m0.png

替代文字 http://img46.imageshack.us/img46/5033/sxbz3mti34afybrafhc32m0.png

Is there any easy way to have several instances of Eclipse open, each one with a different project?

有没有什么简单的方法可以打开多个 Eclipse 实例,每个实例都有不同的项目?

Thanks

谢谢

回答by DaveC

Either create multiple workspaces (Preferences / Startup, tickbox to ask which on every startup)

创建多个工作区(首选项/启动,勾选框在每次启动时询问哪个)

Or more likely, I think Window / New Window will open a second eclipse viewing window on the same workspace.

或者更有可能的是,我认为 Window / New Window 将在同一工作区中打开第二个 eclipse 查看窗口。

回答by bmargulies

yes, each on a differentwokspace.

是的,每个都在不同的工作空间。

Projects and Workspaces in Eclipse are different. A workspace hasa set of global settings and then it hasa set of projects.

Eclipse 中的项目和工作区是不同的。工作区一组全局设置,然后一组项目。

There are two kinds of project. Projects in the workspaceand projects outside the workspace. If you use in the workspace projects (for example, by telling eclipse to make a project via a source control checkout), then it can only be in that workspace.

有两种项目。项目工作区和项目工作区外。如果您在工作区项目中使用(例如,通过告诉 eclipse 通过源代码管理检出创建项目),则它只能在该工作区中。

If you create projects outside the workspace, then you can import each one into as many workspaces as you like.

如果您在工作区之外创建项目,那么您可以将每个项目导入任意数量的工作区。

You can make as many workspaces as you like. Each workspace can be open in only one instance of eclipse.

您可以根据需要创建任意数量的工作区。每个工作区只能在一个 eclipse 实例中打开。

回答by nanda

A better answer to have only the resources from certain project in the new Window is by right clicking the project and select "Open in New Window"

在新窗口中仅包含来自某个项目的资源的更好答案是右键单击该项目并选择“在新窗口中打开”

回答by Desintegr

You may want to use Working sets.

您可能想要使用工作集

A common problem in Eclipse is that your data in your workspace grows and therefore your workspace is not well structured anymore. You can use working sets to organize your displayed projects / data. To setup your working set select in the Package Explorer -> Show -> Working Sets.

Eclipse 中的一个常见问题是您的工作区中的数据不断增长,因此您的工作区不再具有良好的结构。您可以使用工作集来组织您显示的项目/数据。要设置您的工作集,请在 Package Explorer -> Show -> Working Sets 中选择。

回答by Peter Becker

I tend to use different workspaces for different contexts, not just working sets. For that none of the answers above is satisfactory, instead you might want to use the "-data" option on the command line. That allows you to specify the workspace to open, if that is different from the already open one, then a new Eclipse instance will be started.

我倾向于为不同的上下文使用不同的工作区,而不仅仅是工作集。为此,上面的答案都不令人满意,您可能希望在命令行上使用“-data”选项。这允许您指定要打开的工作区,如果它与已经打开的工作区不同,则将启动一个新的 Eclipse 实例。

See http://labs.distriqt.com/post/844for more details.

有关更多详细信息,请参阅http://labs.distriqt.com/post/844

回答by Dom Benedict

There is a way. I have several installations of eclipse in separate folders. Each setup for a different language/job and perspective (CF, Java, Birt). Each has its own workspace so they don't interfere with each other. You can work out if your machine can handle the multiple instances.

有一种方法。我在不同的文件夹中安装了多个 eclipse。不同语言/工作和视角(CF、Java、Birt)的每种设置。每个人都有自己的工作区,所以他们不会相互干扰。您可以确定您的机器是否可以处理多个实例。

回答by Richard Miskin

If you want multiple Eclipse instances open on the same workspace (with the same projects) then you want to use 'Window > New Window'. This will even let you drag views from one window to another.

如果您希望在同一个工作区(具有相同的项目)上打开多个 Eclipse 实例,那么您需要使用“窗口 > 新窗口”。这甚至可以让您将视图从一个窗口拖到另一个窗口。

If you want to display different sets of projects in each Eclipse Window then I'd suggest you use set up a 'Working Set' for each combination of projects you want to work with. You can then select a specific working set from within the Package Explorer. You can create working sets using 'File > New > Java Working Set'.

如果您想在每个 Eclipse 窗口中显示不同的项目集,那么我建议您为要使用的每个项目组合设置一个“工作集”。然后您可以从 Package Explorer 中选择一个特定的工作集。您可以使用“文件 > 新建 > Java 工作集”创建工作集。

Something else to consider is that a Workspace is more than just a group of projects - preferences are all stored at the Workspace level. This means that it is quite easy for your preferences to get out of sync if you work with multiple Workspaces.

还需要考虑的是,工作区不仅仅是一组项目——首选项都存储在工作区级别。这意味着如果您使用多个工作区,您的首选项很容易不同步。

回答by Valentin Rocher

If I understand well, your problem is that you would like not to see the other projects while working on one. What you could do is close the projects you're not working on, and then in the package explorer, choose filters > closed projects. This way the closed projects no longer appear in the package explorer.

如果我理解得很好,您的问题是您不希望在处理一个项目时看到其他项目。您可以做的是关闭您没有处理的项目,然后在包资源管理器中,选择过滤器 > 关闭的项目。这样关闭的项目就不再出现在包浏览器中。