Set up Eclipse as described on the ICU Site.
We use Eclipse for development and testing of our tools.
Make sure you have “Eclipse for Java EE”.
Set up Subversion also, since you'll need it soon.
File->Import, pick SVN, then Projects from SVN.
- (Stop before the heading "Importing ICU4J")
Use the URL
http://unicode.org/repos/cldr for guest access
svn+ssh://unicode.org/repos/cldr for authenticated access (see CLDR Repository Access )
and check out the following projects:
- common ( as a General project )
- seed ( as a General project )
- test ( as a General project )
- java ( as a Java project - it will be named cldr-tools )
- cldr-apps ( as a JavaEE project )
Markus 2012-oct-25: I use command-line svn and checkout the whole CLDR tree. Yoshito says normal developers just need to import one project into Eclipse, from the
Go to Preferences (under Eclipse
on Mac, under Window
- Java>Installed JREs
- Pick 1.7.0
VM arguments: (change red to your
For now, following settings are suggested. (These settings should be done in the CLDR tool's eclipse project file)
- General>Workspace: Text File Encoding: UTF-8
- General>Editors>Text Editors:
- Displayed Tab width: 4
- Insert spaces for tabs
- Show line numbers (optional)
- Java>Code Style>Formatter:
- Profile Name: CLDR
- Indentation Tab
- Tab policy: Spaces Only
- Indentation size: 4
- Tab size: 4
- Align fields in columns
- Line Wrapping Tab
- Maximum line width: 160
- Never Join Lines ✓
Setup User Libraries
Also, you need to set up user libraries as follows
- Java>Build Path>User Libraries
- Click "New" to add following library
- Specify "ANT_LIB" as the user library name
- Get ant libraries from http://ant.apache.org/bindownload.cgi. Extract the contents to a local directory YYY/apache-ant-XXX
- Click "Add External JARs..." and specify the location of "ant.jar" as YYY/apache-ant-XXX/lib/ant.jar
Both unit tests and ConsoleCheckCLDR are hooked up to the continuous build, so make sure to fix any failures before committing your changes.
- Find unittest/TestAll
- Right-click, run as... Java Application.
- When it fails, chose Run Configurations, then retitle that TestAll as TestAll - cldr. In Arguments, add -n -u.
- Hit run.
- Fix any test failures that will occur.
- Go to ConsoleCheckCLDR. Run As... Java Application
- If you get any warnings and errors, fix the relevant files in common/main.
- On my machine, this takes about 5 minutes to run.
Using both Ant and Eclipse
- If you check out 'seed' and 'common' as eclipse projects next to cldr-tools, you can add the following one-line build.properties file in your cldr-tools directory so that ant will find common: