Instructions written for Luna, but should work similarly for Kepler. Earlier versions don't have Maven built-in, so you'll have to install that separately if you don't want to upgrade your Eclipse.
command line: git clone https://github.com/vaadin/charts.git
EGit:
- Open Git repository perspective - Window > Open Perspective > Other... > Git (Windows) - Eclipse > Open Perspective > Other... > Git (Mac)
- click Clone a Git Repository and add the clone to this view
File > Import... > Maven > Existing Maven Projects
You'll need the main project if you want access to the demo or export the demo war. Vaadin 7 version of the add-on is vaadin-charts (addon/pom.xml), and Vaadin 6 version is vaadin-charts-vaadin6 (addon6/pom.xml). Bug fixes should be made to both versions if applicable.
- right-click project > Properties > Project Facets > Convert to faceted form...
- add Vaadin Plug-in for Eclipse and Dynamic Web Module
sync the Eclipse project settings with the pom.xml:
- right-click project > Maven > Update Project
if there are problems in the pom.xml, right-click the problematic place > quick fix > experimental
command line: mvn goal
Eclipse: right-click project > Run As > Maven build... > goal
Note: running the tests might be a problem on Windows laptops at least.
#skipping tests:
Eclipse: check the skip tests when you run any goal
command line: mvn goal -DskipTests
#download dependencies:
goal: install
#compile widgetset:
goal for Vaadin 7: vaadin:compile
goal for Vaadin 6: gwt:compile
#devmode:
goal: vaadin:run
Note: you must first create the launch file. https://vaadin.com/wiki/-/wiki/Main/Debugging+Vaadin+applications
#superdevmode:
goal: vaadin:run-codeserver
#clean:
goal: clean
#run tests:
goal: test
#create demo war:
goal: package (for main project, should appear to /demo/target - for subprojects creates jars)
#more about Maven and Vaadin: https://vaadin.com/wiki/-/wiki/Main/Creating+a+Maven+project
Goals can also be combined, e.g. clean package install
Note: if you run goal clean package install with the skip tests checked,
you must run the vaadin:compile goal before you can run any tests again.
If you try to run some goal and get errors that are related to javadoc, check the stacktrace for what version of maven-javadoc-plugin you are using.
If your version is 2.10, add <version>2.9.1</version> after <artifactId>maven-javadoc-plugin</artifactId> in pom.xml.
The problem should also be fixed in the next version after 2.10 once it's released.
- right-click TServer.java > Run As/Debug As > Java Application
- go to http://localhost:9998/ for a list of all tests (click opens the selected test to another tab) or directly to http://localhost:9998/other/AreaRange or http://localhost:9998/area/AreaSpline etc.
https://vaadin.com/wiki/-/wiki/Main/Contributing+Code
Ensure your Eclipse is set up according to http://dev.vaadin.com/wiki/CodingConventions (except Java6 for Vaadin 7 projects) and https://github.com/vaadin/vaadin#set-up-extra-workspace-preferences
- make sure your project is up to date: - right-click project > Team > Pull
- create a new branch for your change: - right-click project > Team > Switch To > New Branch... - give the branch some suitable name and make sure it's set to checkout the new branch
- right-click project > Team > Commit...
- make sure you have Compute Change-Id For Gerrit Code Review selected
- you may automate this by adding
gerrit.createchangeid = trueto your repository configurations - make sure you included the ticket number to the end of the first line of comment
(#<number>) - make sure there is an empty line before the rest of the comment
- if you need to make further changes, click Amend Previous Commit instead of making a new commit
- make sure you are in the new branch
- make sure Gerrit has your public key (Contributing Code link above)
command line:
- navigate to cloned repository
git push ssh://yourusername@dev.vaadin.com:29418/charts.git head:refs/for/master
EGit:
- make sure eclipse has your private key: - Window > Preferences > search 'ssh' > SSH2 (Windows) - Eclipse > Preferences > search 'ssh' > SSH2 (Mac) - check the path and add the key to the list if necessary
- right-click project > Team > Remote > Configure Push To Upstream...
- Push URIs:
ssh://yourusername@dev.vaadin.com:29418/charts.git- Ref mappings:HEAD:refs/for/master - right-click project > Team > Push to Upstream