Skip to content

Eclipse launcher for developing SonarLint for Eclipse

License

Notifications You must be signed in to change notification settings

thahnen/sonarlint-eclipse-launcher

Repository files navigation

SonarLint for Eclipse: Development launcher

This repository contains common exported launchers for developing SonarLint for Eclipse.

Ant scripts

Some Ant scripts are used for better integration of Maven projects into Eclipse. This is due Maven creating a file named _remote.repositories per artifact downloaded inside the local repository. Running these scripts will remove friction when (re-)loading target platforms

  • sonarlint-java-client-osgi.xml (> 10.1) used for development, OSGi bundle for all client libraries (Java based IDEs)

There is one Ant script used for SonarLint to pick up Eclipse plug-in test projects as they don't necessarily follow the Maven project structure and when the classpath files are generated by Maven/Tycho the test property is not always set correctly:

  • sonarlint-test-classpath.xml used so SonarLint issues are only raised for non-production rules on test source code

IBM Developer for z/OS

Due to SonarLint for Eclipse being also usable in IDz via the integration plug-in provided by IBM, it makes sense from time to time to check whether changes introduce might break the compatiblity (e.g. on changes on the extension points).

For easier testing, there are some Homebrew casks that can be found in the IBM-Developer-for-zOS folder for installation locally (should work on macOS / Linux devices).

A local cask can be installed via

brew install --cask {local repository directory}/IBM-Developer-for-zOS/{formulae name with file suffix} --debug

  • IDz1509.rb for IBM IDz 15.0.9 (05.2024), the latest Java 8 based General Availability
  • IDz1605.rb for IBM IDz 16.0.5 (06.2024), the latest Java 11 based General Availability that should be sufficient when testing
  • IDz1700.rb for IBM IDz 17.0.0 (10.2024), the latest Java 17 based General Availability that should be sufficient when testing

A local cask can be uninstalled via

brew uninstall --force --cask {formulae name without file suffix} --debug

INFO: Currently uninstalling these casks doesn't work correctly as the copied applications are not removed!

Debugging Sloop in Production

In order to debug Sloop we have to have SLCORE 10.x opened in JetBrains IntelliJ Ultimate. After that, we have to start an application via one of the following scripts:

  • debug/eclipse-rcp.sh corresponds to Sloop in Eclipse RCP
  • debug/eclipse-cpp.sh corresponds to Sloop in Eclipse CPP
  • debug/idz-15.0.9.sh corresponds to IBM IDz 15.0.9
  • debug/idz-16.0.5.sh corresponds to IBM IDz 16.0.5
  • debug/idz-17.0.0.sh corresponds to IBM IDz 17.0.0

After that, from within JetBrains IntelliJ Ultimate, we can attach to that specific process (always port 9009).

TODOs:

There are still some things left to do:

  • add Ant script for checking consistency in SLCORE versions between pom.xml / commons.target / MANIFEST.MF
  • add target platform that can be loaded into Eclipse to run IDz instead of a default Eclipse Application

About

Eclipse launcher for developing SonarLint for Eclipse

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published