This page describes the necessary configurations to be able to debug Weasis using an IDE. For developers who want to create new plug-ins, you can visit How to build and install a plug-in.
We recommend the use of IntelliJ IDEA because the following instructions are based on it. Nevertheless, it is possible to use other IDEs by configuring weasis-launcher with similar instructions described in Add a launcher.
Weasis uses google-java-format as coding conventions. The format can be applied by Maven through the Spotless plugin or the IDE. Formatting code with an IDE is not 100% compatible with Spotless, so it is better to use the latter before submitting new commits. This guarantees identical code formatting regardless of the system or code editor used.
See also building the final Weasis Distributions
For running or debugging Weasis, you need to create a launcher:
Open Run > Edit Configurations…
Create a new Application
-Xms64m -Xmx768m -Dgosh.port=17179 --illegal-access=warn
As the default build task has been removed it is necessary to apply the Maven command install on modules with modified code before launching the Run or Debug mode.
Keeping the build task and delegating the build to Maven does not seem configurable for a multi-module project, see this issue.
Examples of launching parameters by entering values in the Program arguments text box
$dicom:get -l \"D:\images test\dicom\"
Some command interpreters need to escape the quotes or double quotes required for paths or URLs. This is the case with IntelliJ IDEA or Eclipse.
For more commands at startup see also Weasis commands.
In Eclipse launcher parameters, ‘&’ within URLs needs to be escaped with a backslash.
Examples of other VM options for overriding the default Preferences
felix.config.properties defines the location of config.properties (the OSGI configuration and the list of plug-ins to install/start)
felix.extended.config.properties defines the location of ext-config.properties (extends/overrides config.properties)