Skip to content

Commit a6672bd

Browse files
ctruedenclaude
andcommitted
Add initial Appose Python script language
Co-authored-by: Claude Sonnet 4.6 <noreply@anthropic.com>
0 parents  commit a6672bd

File tree

12 files changed

+798
-0
lines changed

12 files changed

+798
-0
lines changed

.github/build.sh

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
#!/bin/sh
2+
curl -fsLO https://raw.githubusercontent.com/scijava/scijava-scripts/main/ci-build.sh
3+
sh ci-build.sh

.github/setup.sh

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
#!/bin/sh
2+
curl -fsLO https://raw.githubusercontent.com/scijava/scijava-scripts/main/ci-setup-github-actions.sh
3+
sh ci-setup-github-actions.sh

.github/workflows/build.yml

Lines changed: 36 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,36 @@
1+
name: build
2+
3+
on:
4+
push:
5+
branches:
6+
- main
7+
tags:
8+
- "*-[0-9]+.*"
9+
pull_request:
10+
branches:
11+
- main
12+
13+
jobs:
14+
build:
15+
runs-on: ubuntu-latest
16+
17+
steps:
18+
- uses: actions/checkout@v4
19+
- name: Set up Java
20+
uses: actions/setup-java@v4
21+
with:
22+
java-version: '8'
23+
distribution: 'zulu'
24+
cache: 'maven'
25+
- name: Set up CI environment
26+
run: .github/setup.sh
27+
- name: Execute the build
28+
run: .github/build.sh
29+
env:
30+
GPG_KEY_NAME: ${{ secrets.GPG_KEY_NAME }}
31+
GPG_PASSPHRASE: ${{ secrets.GPG_PASSPHRASE }}
32+
MAVEN_USER: ${{ secrets.MAVEN_USER }}
33+
MAVEN_PASS: ${{ secrets.MAVEN_PASS }}
34+
CENTRAL_USER: ${{ secrets.CENTRAL_USER }}
35+
CENTRAL_PASS: ${{ secrets.CENTRAL_PASS }}
36+
SIGNING_ASC: ${{ secrets.SIGNING_ASC }}

.gitignore

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
/.classpath
2+
/.idea/
3+
/.project
4+
/.settings/
5+
/.vscode/
6+
/target

LICENSE.txt

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
Copyright (c) 2021 - 2025, SciJava developers.
2+
All rights reserved.
3+
4+
Redistribution and use in source and binary forms, with or without modification,
5+
are permitted provided that the following conditions are met:
6+
7+
1. Redistributions of source code must retain the above copyright notice, this
8+
list of conditions and the following disclaimer.
9+
10+
2. Redistributions in binary form must reproduce the above copyright notice,
11+
this list of conditions and the following disclaimer in the documentation
12+
and/or other materials provided with the distribution.
13+
14+
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
15+
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
16+
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
17+
ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE
18+
LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
19+
CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
20+
SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
21+
INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
22+
CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
23+
ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
24+
POSSIBILITY OF SUCH DAMAGE.

README.md

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
[![Build Status](https://github.com/scijava/scripting-appose-python/actions/workflows/build.yml/badge.svg)](https://github.com/scijava/scripting-appose-python/actions/workflows/build.yml)
2+
3+
# Python Scripting with Appose
4+
5+
This library provides a
6+
[JSR-223-compliant](https://en.wikipedia.org/wiki/Scripting_for_the_Java_Platform)
7+
scripting plugin for the [Python](https://python.org/) language, built on
8+
the [appose](https://github.com/apposed/appose-python) Python package.
9+
10+
It is implemented as a `ScriptLanguage` plugin for the [SciJava
11+
Common](https://github.com/scijava/scijava-common) platform, which means that
12+
in addition to being usable directly as a `javax.script.ScriptEngineFactory`,
13+
it also provides some functionality on top.
14+
15+
For a complete list of scripting languages available as part of the SciJava
16+
platform, see the
17+
[Scripting](https://github.com/scijava/scijava-common/wiki/Scripting) page on
18+
the SciJava Common wiki.
19+
20+
See also:
21+
* [Python Scripting](https://imagej.net/scripting/python) on the ImageJ wiki.

pom.xml

Lines changed: 137 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,137 @@
1+
<?xml version="1.0" encoding="UTF-8"?>
2+
<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 https://maven.apache.org/xsd/maven-4.0.0.xsd">
3+
<modelVersion>4.0.0</modelVersion>
4+
5+
<parent>
6+
<groupId>org.scijava</groupId>
7+
<artifactId>pom-scijava</artifactId>
8+
<version>43.0.0</version>
9+
<relativePath />
10+
</parent>
11+
12+
<artifactId>scripting-appose-python</artifactId>
13+
<version>0.4.3-SNAPSHOT</version>
14+
15+
<name>SciJava Scripting: Python</name>
16+
<description>Python scripting language plugin to be used via scyjava.</description>
17+
<url>https://github.com/scijava/scripting-appose-python</url>
18+
<inceptionYear>2021</inceptionYear>
19+
<organization>
20+
<name>SciJava</name>
21+
<url>https://scijava.org/</url>
22+
</organization>
23+
<licenses>
24+
<license>
25+
<name>Simplified BSD License</name>
26+
<distribution>repo</distribution>
27+
</license>
28+
</licenses>
29+
30+
<developers>
31+
<developer>
32+
<id>ctrueden</id>
33+
<name>Curtis Rueden</name>
34+
<url>https://imagej.net/people/ctrueden</url>
35+
<roles>
36+
<role>founder</role>
37+
<role>lead</role>
38+
<role>developer</role>
39+
<role>debugger</role>
40+
<role>reviewer</role>
41+
<role>support</role>
42+
<role>maintainer</role>
43+
</roles>
44+
</developer>
45+
</developers>
46+
<contributors>
47+
<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>
53+
</contributor>
54+
</contributors>
55+
56+
<mailingLists>
57+
<mailingList>
58+
<name>SciJava</name>
59+
<subscribe>https://groups.google.com/group/scijava</subscribe>
60+
<unsubscribe>https://groups.google.com/group/scijava</unsubscribe>
61+
<post>scijava@googlegroups.com</post>
62+
<archive>https://groups.google.com/group/scijava</archive>
63+
</mailingList>
64+
</mailingLists>
65+
66+
<scm>
67+
<connection>scm:git:https://github.com/scijava/scripting-appose-python</connection>
68+
<developerConnection>scm:git:git@github.com:scijava/scripting-appose-python</developerConnection>
69+
<tag>HEAD</tag>
70+
<url>https://github.com/scijava/scripting-appose-python</url>
71+
</scm>
72+
<issueManagement>
73+
<system>GitHub Issues</system>
74+
<url>https://github.com/scijava/scripting-appose-python/issues</url>
75+
</issueManagement>
76+
<ciManagement>
77+
<system>GitHub Actions</system>
78+
<url>https://github.com/scijava/scripting-appose-python/actions</url>
79+
</ciManagement>
80+
81+
<properties>
82+
<package-name>org.scijava.plugins.scripting.appose.python</package-name>
83+
<main-class>org.scijava.plugins.scripting.appose.python.Main</main-class>
84+
85+
<license.licenseName>bsd_2</license.licenseName>
86+
<license.copyrightOwners>SciJava developers.</license.copyrightOwners>
87+
<license.excludes>**/script_templates/**</license.excludes>
88+
89+
<!-- NB: Deploy releases to the SciJava Maven repository. -->
90+
<releaseProfiles>sign,deploy-to-scijava</releaseProfiles>
91+
92+
<appose.version>0.10.0</appose.version>
93+
</properties>
94+
95+
<dependencies>
96+
<!-- SciJava dependencies -->
97+
<dependency>
98+
<groupId>org.scijava</groupId>
99+
<artifactId>scijava-common</artifactId>
100+
</dependency>
101+
<dependency>
102+
<groupId>org.scijava</groupId>
103+
<artifactId>script-editor</artifactId>
104+
</dependency>
105+
106+
<!-- Third-party dependencies -->
107+
<dependency>
108+
<groupId>com.fifesoft</groupId>
109+
<artifactId>rsyntaxtextarea</artifactId>
110+
</dependency>
111+
<dependency>
112+
<groupId>org.apposed</groupId>
113+
<artifactId>appose</artifactId>
114+
<version>${appose.version}</version>
115+
</dependency>
116+
117+
<!-- Test dependencies -->
118+
<dependency>
119+
<groupId>junit</groupId>
120+
<artifactId>junit</artifactId>
121+
<scope>test</scope>
122+
</dependency>
123+
<dependency>
124+
<groupId>org.scijava</groupId>
125+
<artifactId>scijava-common</artifactId>
126+
<classifier>tests</classifier>
127+
<scope>test</scope>
128+
</dependency>
129+
</dependencies>
130+
131+
<repositories>
132+
<repository>
133+
<id>scijava.public</id>
134+
<url>https://maven.scijava.org/content/groups/public</url>
135+
</repository>
136+
</repositories>
137+
</project>

0 commit comments

Comments
 (0)