Eclipseの初期設定メモ
ビルドパス
デフォルトではEclipse内臓のコンパイラなので、JDKのコンパイラに変更。
- Java > Installed JREsでAdd
mac OS Xの場合
> Mac OS X VM > JRE Homeに/Library/Java/JavaVirtualMachines/1.6.0_22-b04-307.jdk/Contents/Homeを指定
Windows 7の場合
M2_REPOとして「C:/Users/<ユーザ名>/.m2/repository」を追加
設定
- General > Workspace のText file encodingをOtherのUTF8にする
- General > Appearance > Colors and FontsのBasic>Text FontをVLゴシック(VL Gothic Font Family)にする。
- General > Editors > Text Editors > Spelling のチェックを外す
- General > Editors > Text Editors のShow line numbersのチェックをON
- Java > Editor > TypingのAutomatically insert at correct positionのsemicolonsとbracesにチェック。
- Java > Editor > FoldingのEnable foldingのチェックを外す
- Java > Editor > Content Assist > Favorite で下記の設定。
Window(ウィンドウ)メニューから、Preferences(設定) > Java > Editor(エディタ) > Content Assist(コンテンツアシスト) > Favorites(お気に入り)を選択します。"New Type"(新規タイプ)ボタンをクリックして、org.hamcrest.CoreMatchers, org.junit.Assert, org.junit.matchers.JUnitMatchers を追加します。
ブランクプロジェクトの作成 - Slim3 日本語サイト(非公式)
- Java > Editor > Syntax Coloring の Java > Local variable declarationsとLocal variable referencesをEnableに。
- Java > Code Style > Organize ImportsのNumber of static Imports need for を 1に。
- Java Code Style > FormatterでNewして新しいフォーマット作成。Line WrappingのMaximum line widthを120にする
- General > WorkspaceでRefresh automaticallyにチェック
- Java > Editor > Templatesから"Test"を下記のように編集。
テンプレート出力時に、hamcrest の Matcher も static import されるように以下のように編集する。
@${testType:newType(org.junit.Test)}
public void ${testname}() throws Exception {
${staticImport:importStatic('org.junit.Assert.*', 'org.hamcrest.CoreMatchers.*')}${cursor}
}全Eclipse Java プログラマーに捧げる Eclispe 徹底活用術完全版〜Eclipseに空気を読ませて楽する術〜 - Yamashiro0217の日記
更新サイト
Help > Install New Softwareから。
Subclipse
http://subclipse.tigris.org/update_1.6.x
【Eclipse】Subversion対応プラグイン Subclipse インストール at softelメモ
Subversive
インストールは、まずTeamProviderだけをインストールしてSVNパースペクティブを開くのが一番早い?更新サイトからやるとうまくいかないことがあった。
- Subversive SVN Team Provider(Incubation)は、Eclipseの更新サイト>Collaborationにある。
- Subversive SVN Connector
- SVNKit
http://community.polarion.com/projects/subversive/download/eclipse/2.0/update-site/
subversiveのSVNKitは更新サイトからじゃなくConnector Discoveryからインストールする - 理系のためのTIPS集