46 lines
1.9 KiB
Markdown
46 lines
1.9 KiB
Markdown
This is a first working state of the plugin. It has not been tested thoroughly. It has not been tested on windows at all.
|
|
|
|
This allows you to mix .java and .jav files in a single project. However, circular dependencies between .java and .jav files are not allowed as both compilers can read .class files but neither is aware of the other source files.
|
|
|
|
In theory, this should not be a problem as JavaTX is supposed to be a superset of Java. In practice however, there are features missing in JavaTX that Java supports (e.g. Arrays)
|
|
|
|
# Installation
|
|
|
|
To install run
|
|
`mvn install`
|
|
in the root of this directory. This will install the plugin to your local maven repository.
|
|
|
|
Then you can use it as a plugin in your maven project by adding the plugin to your project's pom.xml. Make sure to change the javaTXCompilerLocation configuration variable to the correct location.
|
|
It needs to point to a jar file.
|
|
|
|
```
|
|
<build>
|
|
<plugins>
|
|
<plugin>
|
|
<groupId>de.dhbwstuttgart</groupId>
|
|
<artifactId>javatx-compiler-plugin</artifactId>
|
|
<version>1.0-SNAPSHOT</version>
|
|
<configuration>
|
|
<javaTXCompilerLocation>path-to-your-java-tx-compiler-location</javaTXCompilerLocation>
|
|
</configuration>
|
|
<!-- Currently this is the way to override the mvn:compile lifecycle step with this plugin instead of the standard one -->
|
|
<executions>
|
|
<execution>
|
|
<id>custom-compile</id>
|
|
<phase>compile</phase>
|
|
<goals>
|
|
<goal>compile-javatx</goal>
|
|
</goals>
|
|
</execution>
|
|
</executions>
|
|
</plugin>
|
|
|
|
... additional plugins
|
|
</plugins>
|
|
</build>
|
|
```
|
|
|
|
Now you can use the typical `mvn:compile` to compile the project.
|
|
If that fails you may try `mvn javatx-compiler-plugin:compile-javatx` as there could be a bug with overwriting the compile maven lifecycle phase.
|
|
|