导入/导出项目首选项 [英] Importing/Exporting Project Preferences

查看:117
本文介绍了导入/导出项目首选项的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

有一点问题,



由于我们使用源代码控制设置,每个bug /增强功能都在新的分支中进行。这很好,但是在Eclipse中,我们需要为每个分支设置一个新项目。



有没有办法轻松设置项目的默认首选项,或在Eclipse中导入/导出项目偏好?



谢谢,



Stuart

解决方案

一种可能的解决方案是将这些常见首选项存储在Eclipse的工作区级别(参见,项目具体设置在 .classpath .project ,但他没有使用 .settings strong>:



.settings 用于IDE项目特定设置,如编译器警告等。

您要共享项目特定的IDE相关设置,只需将.settings目录从项目目录复制到项目目录。



提示:复制您的项目启动器(默认在< workspace> \.metadata\.plugins\org.eclipse.debug.core\.launch中创建es )插入到您的 .settings 目录中:这样,您也可以共享您的自定义项目启动器。


Having a bit of a problem,

Due to the source-control set-up we use, each bug/enhancement is worked on in a new branch. This is fine, but when in Eclipse, we need to set-up a new project for every branch.

Is there any way of easily setting up default preferences for a project, or importing/exporting project preferences within Eclipse?

Thanks,

Stuart

解决方案

One possible solution would be to store those common preferences at the workspace level for Eclipse (see Manage your Eclipse environment article)

The downside of having multiple workspaces is the need to share development preferences among them.
Since preferences are persisted on a workspace basis within Eclipse, you have to export your workspace preferences and import them to your desired workspaces (File > Export > Preferences).

Even if you stay in the same workspace (with several projects), you can share common settings with other developers by exporting those workspace preferences.

As mentioned by Fabian, the project specific settings are in .classpath and .project, but he left out .settings:

.settings are for IDE project-specific settings like compiler warnings and so on.
It you want to share project-specific IDE-related settings, just copy the .settings directory from project directory to project directory.

Tips: copy your project launcher (created by default in <workspace>\.metadata\.plugins\org.eclipse.debug.core\.launches) into your .settings directory: that way, you will also share your custom project launchers.

这篇关于导入/导出项目首选项的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆