Skip to content

SevNTU plugin for EclipseCS plugin compilation

rnveach edited this page Jan 14, 2018 · 43 revisions

1. I presume that all pages before this you already done, and you did changes to sevntu-checks and eclipsecs-sevntu-plugin projects.

2. Checkout latest tagged eclipse-cs “sources”:

git clone [email protected]:checkstyle/eclipse-cs.git

2.1
Checksout to latest stable version (in example case it is 8.7.0) :

cd eclipse-cs
git checkout 8.7.0

3. Build

mvn install

4. Compile SevNTU sources:

cd ..
cd sevntu-checks
mvn install
cd ../
mvn clean install -f eclipse-pom.xml

result plugin jar is here :
/.m2/repository/com/github/sevntu/checkstyle/eclipsecs-sevntu-plugin/X.X.X/eclipsecs-sevntu-plugin_X.X.X.jar

If you need just to make sevntu-checkstyle projects compilable – that’s all, you don’t need to proceed further. All further steps are necessary for deployment of new sevntu-checkstyle version.


5. save all your changes in remote just in case.

git status
git add .
git commit -m "version was bumped to X.X.X"
git push

6.Do test deploy by scripts to test that all works fine:
./deploy.sh --eclipse-cs
./deploy.sh --maven

7. Copy eclipsecs-sevntu-plugin_X.X.X.jar to Eclipse folder instead of existing jar
Copy sevntu.checkstyle/gh-pages/update-site/plugins/eclipsecs-sevntu-plugin_X.X.X.jar to {ECLIPSE_HOME}/plugins/eclipsecs-sevntu-plugin_X.X.X.jar, launch Eclipse and test your checks from Eclipse. If no problem is found send eclipsecs-sevntu-plugin_X.X.X.jar your mentor for review and testing.

8. Test your version of plugin in Eclipse – manual , create configuration with only your Check, import required projects for testing, do not forget recheck that EclipseCS is activated on them in project properties.

9. Test your build yourself on Opensource projects: how to


Alternative way to create JAR for testing:

1. To create Plugin jar

Select project “eclipsecs-sevntu-plugin”, in context menu “Export → Plug-in Deployment/Deployable plug-ins and fragments”. Press “Next” . Provide Destination Directory. Press “Finish”.

2. Add plugin to eclipse

Result jar – eclipsecs-sevntu-plugin_X.X.X.jar. Should be copied to /pligins. Launch Eclipse. Select menu – Window – Preferences → Checkstyle. Select Configuration and press “Configure”. In list of groups will be “SevNTU checks”. Enjoy.