yak4j-cli
Used in:
components
- OverviewOverview
- VersionsVersions
- DependentsDependents
- DependenciesDependencies
<dependency>
<groupId>com.github.ngeor</groupId>
<artifactId>yak4j-cli</artifactId>
<version>0.10.0</version>
</dependency><?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 http://maven.apache.org/maven-v4_0_0.xsd">
<parent>
<artifactId>java</artifactId>
<groupId>com.github.ngeor</groupId>
<version>1.10.0</version>
<relativePath>../../pom.xml</relativePath>
</parent>
<modelVersion>4.0.0</modelVersion>
<artifactId>yak4j-cli</artifactId>
<name>yak4j-cli</name>
<version>0.10.0</version>
<description>Interactive CLI for yak4j</description>
<build>
<plugins>
<plugin>
<artifactId>maven-compiler-plugin</artifactId>
<configuration>
<annotationProcessorPaths>
<path>
<groupId>info.picocli</groupId>
<artifactId>picocli-codegen</artifactId>
<version>4.6.1</version>
</path>
</annotationProcessorPaths>
<compilerArgs>
<arg>-Aproject=${project.groupId}/${project.artifactId}</arg>
</compilerArgs>
</configuration>
</plugin>
<plugin>
<artifactId>maven-jar-plugin</artifactId>
<configuration>
<archive>
<manifest>
<mainClass>com.github.ngeor.yak4jcli.Main</mainClass>
</manifest>
</archive>
</configuration>
</plugin>
<plugin>
<artifactId>maven-shade-plugin</artifactId>
<executions>
<execution>
<phase>package</phase>
<goals>
<goal>shade</goal>
</goals>
</execution>
</executions>
<configuration>
<minimizeJar>true</minimizeJar>
</configuration>
</plugin>
<plugin>
<artifactId>maven-source-plugin</artifactId>
</plugin>
<plugin>
<artifactId>maven-javadoc-plugin</artifactId>
</plugin>
<plugin>
<groupId>org.codehaus.gmaven</groupId>
<artifactId>groovy-maven-plugin</artifactId>
<executions>
<execution>
<phase>generate-sources</phase>
<goals>
<goal>execute</goal>
</goals>
<configuration>
<source>import java.nio.charset.StandardCharsets
import java.nio.file.Files
import java.nio.file.Path
def lines = [
'#!/usr/bin/env bash',
'# This script is automatically generated, do not edit manually.',
'# Re-generate the script with mvn package -pl apps/${project.artifactId} -am',
'set -e',
'JAR_NAME=${project.artifactId}-${project.version}.jar',
'SOURCE_JAR=apps/${project.artifactId}/target/$' + '{JAR_NAME}',
'if [[ ! -r $' + '{SOURCE_JAR} ]]; then',
' mvn package -pl apps/${project.artifactId} -am',
'fi',
'# Use jar from a temp location, to be able to clean the folder of yak4j-cli',
'TEMP_JAR=$' + '{TMP}/$' + '{JAR_NAME}',
'# Delete the temp file upon exit',
'trap "{ rm $' + '{TEMP_JAR}; }" EXIT',
'cp $' + '{SOURCE_JAR} $' + '{TEMP_JAR}',
'java -jar $' + '{TEMP_JAR} $*',
''
]
def contents = lines.join('\n')
Files.write(Path.of('scripts', '${project.artifactId}.sh'), contents.getBytes(StandardCharsets.UTF_8))</source>
</configuration>
</execution>
</executions>
</plugin>
</plugins>
</build>
<dependencies>
<dependency>
<groupId>org.junit.jupiter</groupId>
<artifactId>junit-jupiter</artifactId>
<version>5.7.2</version>
<scope>test</scope>
<exclusions>
<exclusion>
<artifactId>junit-jupiter-api</artifactId>
<groupId>org.junit.jupiter</groupId>
</exclusion>
<exclusion>
<artifactId>junit-jupiter-params</artifactId>
<groupId>org.junit.jupiter</groupId>
</exclusion>
<exclusion>
<artifactId>junit-jupiter-engine</artifactId>
<groupId>org.junit.jupiter</groupId>
</exclusion>
</exclusions>
</dependency>
</dependencies>
</project>