在 Eclipse 中创建一个新工作区

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/7234656/
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-10 20:28:24  来源:igfitidea点击:

Create a new workspace in Eclipse

eclipseworkspace

提问by BigUser

I don't see any menu item I can use to create a new workspace.

我没有看到任何可用于创建新工作区的菜单项。

What should I use to create a new workspace and move some of the projects from existing default workspace to a new workspace?

我应该使用什么来创建新工作区并将某些项目从现有默认工作区移动到新工作区?

I am using Windows with Eclipse 3.7.

我在 Eclipse 3.7 中使用 Windows。

回答by rajah9

I use File -> Switch Workspace -> Other... and type in my new workspace name.

我使用 File -> Switch Workspace -> Other... 并输入我的新工作区名称。

New workspace composite screenshot(EDIT: Added the composite screen shot.)

新建工作区复合截图(编辑:添加了复合屏幕截图。)

Once in the new workspace, File -> Import... and under General choose "Existing Projects into Workspace. Press the Next button and then Browse for the old projects you would like to import. Check "Copy projects into workspace" to make a copy.

进入新工作区后,文件 -> 导入...并在常规下选择“现有项目到工作区。按下一步按钮,然后浏览要导入的旧项目。选中“将项目复制到工作区”以制作复制。

回答by revdrjrr

In Window->Preferences->General->Startup and Shutdown->Workspaces, make sure that 'Prompt for Workspace on startup' is checked.

Window->Preferences->General->Startup and Shutdown->Workspaces 中,确保选中“Prompt for Workspace on startup”。

Then close eclipse and reopen.

然后关闭eclipse并重新打开。

Then you'll be prompted for a workspace to open. You can create a new workspace from that dialogue.

然后系统会提示您打开工作区。您可以从该对话框创建一个新工作区。

Or File->Switch Workspace->Other...

或者文件->切换工作区->其他...

回答by Nirbhay Mishra

You can create multiple workspaces in Eclipse. You have to just specify the path of the workspace during Eclipse startup. You can even switch workspaces via File→Switch workspace.

您可以在 Eclipse 中创建多个工作区。您只需在 Eclipse 启动期间指定工作区的路径。您甚至可以通过文件→切换工作区来切换工作区。

You can then import project to your workspace, copy paste project to your new workspace folder, then

然后您可以将项目导入到您的工作区,将粘贴项目复制到您的新工作区文件夹,然后

File→Import→Existing project in to workspace→select project.

文件→导入→现有项目到工作区→选择项目。