blob: f4b35e25b611f2d715a8f897f8092e154b8f1e66 [file] [log] [blame]
Shawn O. Pearcee31d02c2009-12-08 12:21:37 -08001Gerrit Code Review - Eclipse Setup
2==================================
Shawn O. Pearced2b73db2009-01-09 11:55:47 -08003
Shawn O. Pearce18f1f7f2009-12-16 11:32:39 -08004This document is about configuring Gerrit Code Review into an
Shawn O. Pearce5eaf5d92009-12-21 15:16:10 -08005Eclipse workspace for development and debugging with GWT.
Shawn O. Pearced2b73db2009-01-09 11:55:47 -08006
Shawn O. Pearce5eaf5d92009-12-21 15:16:10 -08007Java 6 or later SDK is also required to run GWT's compiler and
8runtime debugging environment.
Shawn O. Pearced2b73db2009-01-09 11:55:47 -08009
Shawn O. Pearce18f1f7f2009-12-16 11:32:39 -080010
Shawn O. Pearced2b73db2009-01-09 11:55:47 -080011Maven Plugin
12------------
13
14Install the Maven Integration plugins:
15
16http://m2eclipse.codehaus.org/[m2eclipse]
17
18
Shawn O. Pearcee89544b2009-04-28 07:59:44 -070019Code Formatter Settings
20-----------------------
21
Shawn O. Pearce44671f52009-11-07 12:55:26 -080022Import `tools/GoogleFormat.xml` using Window -> Preferences ->
23Java -> Code Style -> Formatter -> Import...
Shawn O. Pearcee89544b2009-04-28 07:59:44 -070024
25This will define the 'Google Format' profile, which the project
26settings prefer when formatting source code.
27
28
Shawn O. Pearced2b73db2009-01-09 11:55:47 -080029Import Projects
30---------------
31
Shawn O. Pearce263786e2009-02-02 15:49:26 -080032Import pom.xml using General -> Maven Projects
Shawn O. Pearced2b73db2009-01-09 11:55:47 -080033
Shawn O. Pearce18f1f7f2009-12-16 11:32:39 -080034Some of the source code is generated with ANTLR sources. To build
35these files, right click on the imported projects, Maven -> Update
36Project Configuration. This will resolve compile errors identified
37after import.
Shawn O. Pearced2b73db2009-01-09 11:55:47 -080038
39
Shawn O. Pearce18f1f7f2009-12-16 11:32:39 -080040Site Initialization
41-------------------
Shawn O. Pearced2b73db2009-01-09 11:55:47 -080042
Shawn O. Pearce18f1f7f2009-12-16 11:32:39 -080043link:dev-readme.html#build[Build] once on the command line and
44then follow link:dev-readme.html#init[Site Initialization] in the
45Developer Setup guide to configure a local site for testing.
Shawn O. Pearced2b73db2009-01-09 11:55:47 -080046
Shawn O. Pearced2b73db2009-01-09 11:55:47 -080047
Shawn O. Pearce18f1f7f2009-12-16 11:32:39 -080048Testing
49-------
Shawn O. Pearce8d2f1842009-05-13 07:59:04 -070050
Shawn O. Pearce18f1f7f2009-12-16 11:32:39 -080051Running the Daemon
52~~~~~~~~~~~~~~~~~~
Shawn O. Pearce8d2f1842009-05-13 07:59:04 -070053
Shawn O. Pearce18f1f7f2009-12-16 11:32:39 -080054Duplicate the existing `pgm_daemon` launch configuration:
Shawn O. Pearce8d2f1842009-05-13 07:59:04 -070055
Shawn O. Pearce18f1f7f2009-12-16 11:32:39 -080056* Run -> Debug Configurations ...
57* Java Application -> `pgm_daemon`
58* Right click, Duplicate
Shawn O. Pearced2b73db2009-01-09 11:55:47 -080059
Shawn O. Pearce18f1f7f2009-12-16 11:32:39 -080060* Modify the name to be unique.
Shawn O. Pearced2b73db2009-01-09 11:55:47 -080061
Shawn O. Pearce18f1f7f2009-12-16 11:32:39 -080062* Switch to Arguments tab.
Shawn O. Pearce955d00e2009-12-19 13:38:19 -080063* Edit the `-d` program argument flag to match the path used during
64 'init'. The template launch configuration resolves to ../test_site
65 since that is what the documentation recommends.
Shawn O. Pearced2b73db2009-01-09 11:55:47 -080066
Shawn O. Pearce18f1f7f2009-12-16 11:32:39 -080067* Switch to Common tab.
68* Change Save as to be Local file.
Shawn O. Pearce06b48c32009-05-10 16:21:05 -070069
Shawn O. Pearce06b48c32009-05-10 16:21:05 -070070
Shawn O. Pearce18f1f7f2009-12-16 11:32:39 -080071Running Hosted Mode
72~~~~~~~~~~~~~~~~~~~
Shawn O. Pearce06b48c32009-05-10 16:21:05 -070073
Shawn O. Pearce5eaf5d92009-12-21 15:16:10 -080074Duplicate the existing `gwtui_dbg` launch configuration:
Shawn O. Pearce955d00e2009-12-19 13:38:19 -080075
76* Run -> Debug Configurations ...
Shawn O. Pearce5eaf5d92009-12-21 15:16:10 -080077* Java Application -> `gwtui_dbg`
Shawn O. Pearce955d00e2009-12-19 13:38:19 -080078* Right click, Duplicate
79
80* Modify the name to be unique.
81
82* Switch to Arguments tab.
83* Edit the `-Dgerrit.site_path=` VM argument to match the path
84 used during 'init'. The template launch configuration resolves
85 to ../test_site since that is what the documentation recommends.
86
87* Switch to Common tab.
88* Change Save as to be Local file.
Shawn O. Pearce06b48c32009-05-10 16:21:05 -070089
Shawn O. Pearce5500e692009-05-28 15:55:01 -070090
91GERRIT
92------
93Part of link:index.html[Gerrit Code Review]