Skip to content

Commit 19473da

Browse files
committed
Modularize project
1 parent ad90fe1 commit 19473da

2 files changed

Lines changed: 93 additions & 8 deletions

File tree

‎pom.xml‎

Lines changed: 43 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
</parent>
1111

1212
<artifactId>scripting-appose-python</artifactId>
13-
<version>0.1.1-SNAPSHOT</version>
13+
<version>0.2.0-SNAPSHOT</version>
1414

1515
<name>SciJava Scripting: Appose Python</name>
1616
<description>Python scripting language plugin backed by Appose.</description>
@@ -45,11 +45,9 @@
4545
</developers>
4646
<contributors>
4747
<contributor>
48-
<!--
49-
NB: Need at least one element to override the parent.
50-
See: https://issues.apache.org/jira/browse/MNG-5220
51-
-->
52-
<name>None</name>
48+
<name>Gabriel Selzer</name>
49+
<url>https://imagej.net/people/gselzer</url>
50+
<properties><id>gselzer</id></properties>
5351
</contributor>
5452
</contributors>
5553

@@ -82,6 +80,8 @@
8280
<package-name>org.scijava.plugins.scripting.appose.python</package-name>
8381
<main-class>org.scijava.plugins.scripting.appose.python.Main</main-class>
8482

83+
<surefire.useModulePath>false</surefire.useModulePath>
84+
8585
<license.licenseName>bsd_2</license.licenseName>
8686
<license.copyrightOwners>SciJava developers.</license.copyrightOwners>
8787
<license.excludes>**/script_templates/**</license.excludes>
@@ -96,8 +96,8 @@
9696
NB: Task#log() needs it. -->
9797
<scijava-common.version>2.101.0</scijava-common.version>
9898

99-
<scijava-lsp.version>0.1.0-SNAPSHOT</scijava-lsp.version>
100-
<scijava-lsp-ty.version>0.1.0-SNAPSHOT</scijava-lsp-ty.version>
99+
<scijava-lsp.version>0.1.0</scijava-lsp.version>
100+
<scijava-lsp-ty.version>0.1.0</scijava-lsp-ty.version>
101101
</properties>
102102

103103
<dependencies>
@@ -183,4 +183,39 @@
183183
<url>https://maven.scijava.org/content/groups/public</url>
184184
</repository>
185185
</repositories>
186+
187+
<build>
188+
<plugins>
189+
<!--
190+
NB: Tests run on the classpath since we use scijava-common's tests JAR.
191+
That JAR shares the org.scijava module name with scijava-common itself, so
192+
it cannot be resolved on the module path.
193+
-->
194+
<plugin>
195+
<groupId>org.apache.maven.plugins</groupId>
196+
<artifactId>maven-compiler-plugin</artifactId>
197+
<configuration>
198+
<!--
199+
NB: In module mode, javac does not discover annotation processors
200+
on the module path, so the @Plugin indexer must be declared here.
201+
-->
202+
<annotationProcessorPaths>
203+
<path>
204+
<groupId>org.scijava</groupId>
205+
<artifactId>scijava-common</artifactId>
206+
<version>${scijava-common.version}</version>
207+
</path>
208+
</annotationProcessorPaths>
209+
</configuration>
210+
<executions>
211+
<execution>
212+
<id>default-testCompile</id>
213+
<configuration>
214+
<useModulePath>false</useModulePath>
215+
</configuration>
216+
</execution>
217+
</executions>
218+
</plugin>
219+
</plugins>
220+
</build>
186221
</project>

‎src/main/java/module-info.java‎

Lines changed: 50 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,50 @@
1+
/*
2+
* #%L
3+
* Python scripting language plugin backed by Appose.
4+
* %%
5+
* Copyright (C) 2026 SciJava developers.
6+
* %%
7+
* Redistribution and use in source and binary forms, with or without
8+
* modification, are permitted provided that the following conditions are met:
9+
*
10+
* 1. Redistributions of source code must retain the above copyright notice,
11+
* this list of conditions and the following disclaimer.
12+
* 2. Redistributions in binary form must reproduce the above copyright notice,
13+
* this list of conditions and the following disclaimer in the documentation
14+
* and/or other materials provided with the distribution.
15+
*
16+
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
17+
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
18+
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
19+
* ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDERS OR CONTRIBUTORS BE
20+
* LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
21+
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
22+
* SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
23+
* INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
24+
* CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
25+
* ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
26+
* POSSIBILITY OF SUCH DAMAGE.
27+
* #L%
28+
*/
29+
30+
module scripting.appose.python {
31+
32+
exports org.scijava.plugins.scripting.appose.python;
33+
exports org.scijava.plugins.scripting.appose.python.completion;
34+
35+
opens org.scijava.plugins.scripting.appose.python to org.scijava;
36+
opens org.scijava.plugins.scripting.appose.python.completion to org.scijava;
37+
38+
requires com.fasterxml.jackson.core;
39+
requires com.fasterxml.jackson.databind;
40+
requires com.fasterxml.jackson.dataformat.toml;
41+
requires java.scripting;
42+
requires net.imagej;
43+
requires net.imglib2;
44+
requires net.imglib2.appose;
45+
requires org.apposed.appose;
46+
requires org.fife.RSyntaxTextArea;
47+
requires org.scijava;
48+
requires org.scijava.lsp;
49+
requires org.scijava.ui.swing.script;
50+
}

0 commit comments

Comments
 (0)