WIP: adding jlink build step
This commit is contained in:
parent
3175339bae
commit
5da8a2edd8
6 changed files with 63 additions and 21 deletions
|
@ -11,28 +11,13 @@
|
||||||
<files>
|
<files>
|
||||||
<file>
|
<file>
|
||||||
<source>src/main/resources/run.sh</source>
|
<source>src/main/resources/run.sh</source>
|
||||||
<outputDirectory></outputDirectory>
|
<outputDirectory/>
|
||||||
<filtered>true</filtered>
|
<filtered>true</filtered>
|
||||||
</file>
|
</file>
|
||||||
</files>
|
</files>
|
||||||
<dependencySets>
|
<dependencySets>
|
||||||
<dependencySet>
|
<dependencySet>
|
||||||
<outputDirectory>libs</outputDirectory>
|
<outputDirectory>libs</outputDirectory>
|
||||||
<excludes>
|
|
||||||
<exclude>nu.zoom.dsl:parser:*</exclude>
|
|
||||||
</excludes>
|
|
||||||
<useStrictFiltering>true</useStrictFiltering>
|
|
||||||
<outputFileNameMapping>${artifact.artifactId}-${artifact.baseVersion}.${artifact.extension}</outputFileNameMapping>
|
|
||||||
<useTransitiveDependencies>true</useTransitiveDependencies>
|
|
||||||
<unpack>false</unpack>
|
|
||||||
<scope>runtime</scope>
|
|
||||||
<useProjectArtifact>false</useProjectArtifact>
|
|
||||||
</dependencySet>
|
|
||||||
<dependencySet>
|
|
||||||
<outputDirectory></outputDirectory>
|
|
||||||
<includes>
|
|
||||||
<include>nu.zoom.dsl:parser:*</include>
|
|
||||||
</includes>
|
|
||||||
<useStrictFiltering>true</useStrictFiltering>
|
<useStrictFiltering>true</useStrictFiltering>
|
||||||
<outputFileNameMapping>${artifact.artifactId}-${artifact.baseVersion}.${artifact.extension}</outputFileNameMapping>
|
<outputFileNameMapping>${artifact.artifactId}-${artifact.baseVersion}.${artifact.extension}</outputFileNameMapping>
|
||||||
<useTransitiveDependencies>true</useTransitiveDependencies>
|
<useTransitiveDependencies>true</useTransitiveDependencies>
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
#! /bin/sh
|
#! /bin/bash
|
||||||
|
set -euo pipefail
|
||||||
SCRIPT_DIR=$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )
|
SCRIPT_DIR=$( cd -- "$( dirname -- "${BASH_SOURCE[0]}" )" &> /dev/null && pwd )
|
||||||
cd "${SCRIPT_DIR}"
|
java --module-path "${SCRIPT_DIR}"/libs -m nu.zoom.endgen/nu.zoom.dsl.cli.EndpointsCLI "$@"
|
||||||
java -jar parser-${artifact.baseVersion}.jar "$@"
|
|
49
endgen-jlink/pom.xml
Normal file
49
endgen-jlink/pom.xml
Normal file
|
@ -0,0 +1,49 @@
|
||||||
|
<?xml version="1.0" encoding="UTF-8"?>
|
||||||
|
<!--
|
||||||
|
// Copyright 2025 "Johan Maasing" <johan@zoom.nu>
|
||||||
|
//
|
||||||
|
// Licensed under the Apache License, Version 2.0 (the "License");
|
||||||
|
// you may not use this file except in compliance with the License.
|
||||||
|
// You may obtain a copy of the License at
|
||||||
|
//
|
||||||
|
// http://www.apache.org/licenses/LICENSE-2.0
|
||||||
|
//
|
||||||
|
// Unless required by applicable law or agreed to in writing, software
|
||||||
|
// distributed under the License is distributed on an "AS IS" BASIS,
|
||||||
|
// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
||||||
|
// See the License for the specific language governing permissions and
|
||||||
|
// limitations under the License.
|
||||||
|
-->
|
||||||
|
<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 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
||||||
|
<modelVersion>4.0.0</modelVersion>
|
||||||
|
|
||||||
|
<parent>
|
||||||
|
<groupId>nu.zoom.dsl</groupId>
|
||||||
|
<artifactId>endgen</artifactId>
|
||||||
|
<version>1.3-SNAPSHOT</version>
|
||||||
|
</parent>
|
||||||
|
|
||||||
|
<artifactId>endgen-jlink</artifactId>
|
||||||
|
|
||||||
|
<dependencies>
|
||||||
|
<dependency>
|
||||||
|
<groupId>nu.zoom.dsl</groupId>
|
||||||
|
<artifactId>parser</artifactId>
|
||||||
|
<version>${project.parent.version}</version>
|
||||||
|
</dependency>
|
||||||
|
</dependencies>
|
||||||
|
|
||||||
|
<build>
|
||||||
|
<plugins>
|
||||||
|
<plugin>
|
||||||
|
<groupId>org.apache.maven.plugins</groupId>
|
||||||
|
<artifactId>maven-jlink-plugin</artifactId>
|
||||||
|
<version>3.2.0</version>
|
||||||
|
<extensions>true</extensions>
|
||||||
|
<configuration>
|
||||||
|
<!-- configuration elements goes here -->
|
||||||
|
</configuration>
|
||||||
|
</plugin>
|
||||||
|
</plugins>
|
||||||
|
</build>
|
||||||
|
</project>
|
|
@ -52,6 +52,7 @@
|
||||||
<configuration>
|
<configuration>
|
||||||
<source>${maven.compiler.source}</source>
|
<source>${maven.compiler.source}</source>
|
||||||
<target>${maven.compiler.target}</target>
|
<target>${maven.compiler.target}</target>
|
||||||
|
<release>${maven.compiler.target}</release>
|
||||||
</configuration>
|
</configuration>
|
||||||
</plugin>
|
</plugin>
|
||||||
<plugin>
|
<plugin>
|
||||||
|
@ -61,9 +62,9 @@
|
||||||
<configuration>
|
<configuration>
|
||||||
<archive>
|
<archive>
|
||||||
<manifest>
|
<manifest>
|
||||||
<classpathPrefix>libs/</classpathPrefix>
|
|
||||||
<addClasspath>true</addClasspath>
|
|
||||||
<mainClass>nu.zoom.dsl.cli.EndpointsCLI</mainClass>
|
<mainClass>nu.zoom.dsl.cli.EndpointsCLI</mainClass>
|
||||||
|
<addDefaultImplementationEntries>true</addDefaultImplementationEntries>
|
||||||
|
<addDefaultSpecificationEntries>true</addDefaultSpecificationEntries>
|
||||||
</manifest>
|
</manifest>
|
||||||
</archive>
|
</archive>
|
||||||
</configuration>
|
</configuration>
|
||||||
|
|
6
parser/src/main/java/module-info.java
Normal file
6
parser/src/main/java/module-info.java
Normal file
|
@ -0,0 +1,6 @@
|
||||||
|
module nu.zoom.endgen {
|
||||||
|
requires freemarker;
|
||||||
|
requires info.picocli;
|
||||||
|
requires org.antlr.antlr4.runtime;
|
||||||
|
opens nu.zoom.dsl.cli to info.picocli;
|
||||||
|
}
|
1
pom.xml
1
pom.xml
|
@ -66,6 +66,7 @@
|
||||||
<module>parser</module>
|
<module>parser</module>
|
||||||
<module>endgen-dist</module>
|
<module>endgen-dist</module>
|
||||||
<module>endgen-maven-plugin</module>
|
<module>endgen-maven-plugin</module>
|
||||||
|
<module>endgen-jlink</module>
|
||||||
</modules>
|
</modules>
|
||||||
|
|
||||||
</project>
|
</project>
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue