Files
runway/plugins/search/pom.xml
T
2026-10-29 09:22:38 -06:00

140 lines
7.4 KiB
XML

<?xml version="1.0" encoding="UTF-8"?>
<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">
<modelVersion>4.0.0</modelVersion>
<!--
Inherit the SAME managed versions the Runway kernel uses (Spring Boot 4.0.6), so every `provided`
Spring type the plugin compiles against is byte-identical to the class the host loads. A plugin is NOT
a Spring Boot application — NO spring-boot-maven-plugin repackage; `mvn package` produces a THIN jar of
only this plugin's own classes (including its published SPI — SiteSearchEngine, SearchCorpus, SearchQuery,
SearchHit — which search-lucene compiles against as `provided`).
-->
<parent>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-parent</artifactId>
<version>4.0.6</version>
<relativePath/>
</parent>
<groupId>mx.quest</groupId>
<artifactId>runway-plugin-search</artifactId>
<version>2.3.1</version>
<packaging>jar</packaging>
<name>Runway Search Plugin</name>
<licenses>
<license>
<name>GNU Affero General Public License v3.0, with the Runway additional permission for plugins</name>
<url>https://www.gnu.org/licenses/agpl-3.0.txt</url>
<distribution>repo</distribution>
<comments>See LICENSE and LICENSE-EXCEPTION.</comments>
</license>
</licenses>
<description>
On-site search for Runway: a built-in full-text engine over the site's published pages and content items,
an embeddable query-aware search-box content widget, and a JSON API — all backed by a published
SiteSearchEngine SPI (and the SearchCorpus every engine builds from) that a companion plugin (search-lucene)
can implement to transparently upgrade the engine. Links only the Runway SPI.
</description>
<properties>
<java.version>25</java.version>
<maven.compiler.release>25</maven.compiler.release>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<!-- Reproducible builds: pins every archive entry's timestamp so two builds of the same source
produce byte-identical artifacts. Without it a jar embeds the build time, so a rebuild can
never match what was published. Bump at each release. -->
<project.build.outputTimestamp>2026-10-21T19:31:00Z</project.build.outputTimestamp>
<!-- The runway-spi (and runway-spi-testkit) version this plugin compiles and tests against, from ~/.m2. -->
<runway.version>1.0.0</runway.version>
</properties>
<dependencies>
<!-- The dependency-free extension API (SPI interfaces + immutable model records). COMPILE. -->
<dependency>
<groupId>mx.quest</groupId>
<artifactId>runway-spi</artifactId>
<version>${runway.version}</version>
</dependency>
<!-- NO runway-app dependency, in any scope: the plugin links only the SPI, so a host
import no longer compiles and the kernel's host-linkage scanner finds nothing to report. -->
<dependency>
<groupId>mx.quest</groupId>
<artifactId>runway-spi-testkit</artifactId>
<version>${runway.version}</version>
<scope>test</scope>
</dependency>
<!-- Spring context/Boot for @Configuration/@Bean at compile time; host-provided at runtime. -->
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter</artifactId>
<scope>provided</scope>
</dependency>
<!-- Wiring/unit tests run against the compiled classes (NEVER spring-boot:run). -->
<dependency>
<groupId>org.springframework.boot</groupId>
<artifactId>spring-boot-starter-test</artifactId>
<scope>test</scope>
</dependency>
</dependencies>
<build>
<!-- Stable deployed filename (no version/classifier): target/runway-plugin-search.jar. -->
<finalName>runway-plugin-search</finalName>
<plugins>
<!-- After the jar is built, assemble BOTH installable forms the platform accepts:
1. target/search/ — the install-ready folder (cp -r into external/plugins/ + restart).
2. target/runway-plugin-search-<version>.zip — the UI-uploadable archive (/__app/plugins). -->
<plugin>
<artifactId>maven-antrun-plugin</artifactId>
<executions>
<execution>
<id>assemble-plugin-folder</id>
<phase>package</phase>
<goals>
<goal>run</goal>
</goals>
<configuration>
<target>
<property name="stage" value="${project.build.directory}/search"/>
<delete dir="${stage}"/>
<mkdir dir="${stage}"/>
<copy file="${project.basedir}/plugin.yml" todir="${stage}"/>
<copy file="${project.basedir}/LICENSE" todir="${stage}"/>
<copy file="${project.basedir}/LICENSE-EXCEPTION" todir="${stage}"/>
<copy file="${project.build.directory}/runway-plugin-search.jar" todir="${stage}"/>
<copy todir="${stage}/static">
<fileset dir="${project.basedir}/static"/>
</copy>
<copy todir="${stage}/templates">
<fileset dir="${project.basedir}/templates"/>
</copy>
<copy todir="${stage}/i18n">
<fileset dir="${project.basedir}/i18n"/>
</copy>
<touch datetime="${project.build.outputTimestamp}"
pattern="yyyy-MM-dd'T'HH:mm:ss'Z'">
<fileset dir="${stage}"/>
<dirset dir="${stage}"/>
<dirset dir="${project.build.directory}" includes="search"/>
</touch>
<!-- The stamped files predate any earlier zip, so <zip> would skip the rebuild. -->
<delete file="${project.build.directory}/runway-plugin-search-${project.version}.zip"/>
<zip destfile="${project.build.directory}/runway-plugin-search-${project.version}.zip">
<zipfileset dir="${project.build.directory}" includes="search/**"/>
</zip>
<echo message="Staged install folder: ${stage}"/>
<echo message="UI-uploadable archive: ${project.build.directory}/runway-plugin-search-${project.version}.zip"/>
</target>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
</project>