eclipse-platform / eclipse-platform/eclipse.platform
Support hierarchical project preferences
- 主要言語
- Java
- スター
- 165
- フォーク
- 174
- 平均マージ
- 2日 8時間
- マージ済み PR(30日)
- 22
説明
Currently project preferences are stored in a folder named `.settings` this has the drawback that if one want to configure an aspect for a set of projects (e.g. formatter settings, compiler preferences, ...) one need to duplicate this (and keep them up to date) for each project. Also wen VCS comes into account the same files need to be versioned multiple times.
To mitigate this and given that most projects have some hierarchical nature (e.g the usual `/plugins/`) I'd like to propose the following enhancement (using `org.eclipse.jdt.core.prefs` as an example):
- Given there is a file `.settings/org.eclipse.jdt.core.prefs` nothing changes
- Given there is no file `.settings/org.eclipse.jdt.core.prefs` then first a file `.eclipse/org.eclipse.jdt.core.prefs` is searched and if found that is used, if that file is not found, the parent folder is checked for this until the root is reached
- If still no file is found `/.eclipse//org.eclipse.jdt.core.prefs` is searched as a last resort
This would allow to have a variety of different use cases:
1. In cases where a user chooses to "enable project specific settings" for certain settings, one could add a new option to not store it in the *project* but in the *workspace*, e.g. if I want to prevent the noise if I open a project that normally do not store eclipse preferences.
2. I might use this to enable some project specific settings for a set of projects e.g. by placing it in the `/plugins/.eclipse` folder.
3. I even configure some things on the root of the project e.g. placing a `/.eclipse/org.eclipse.core.resources.prefs` to force UTF-8 for the usual source folders.
4. ...
コントリビューションガイド
調査の方向性
.settings/org.eclipse.jdt.core.prefs の既存の処理と、プロジェクト設定の検索エントリーポイントを特定することから始めます。その動作を、提案されている .eclipse 階層および workspace fallback と比較します。文書化された検索順序が、既存のプロジェクトローカルな設定の動作を変更せずに機能すれば完了です。
索引モデルが issue の本文から書いたものです。
評価
- 技術スタック
- java
- 領域
- tooling
- issue の種類
- 機能追加
- 難易度
- 5/5
- 見積もり時間
- 1週間以上
- 活発さ
- 停滞
- 明瞭さ
- おおむね明確
- 初心者へのやさしさ
- 25/100