150 lines
6.6 KiB
XML
150 lines
6.6 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 http://maven.apache.org/xsd/maven-4.0.0.xsd">
|
|
|
|
<modelVersion>4.0.0</modelVersion>
|
|
<groupId>me.sashegdev</groupId>
|
|
<artifactId>ZernMCLauncher</artifactId>
|
|
<version>1.0.4</version>
|
|
<packaging>jar</packaging>
|
|
|
|
<properties>
|
|
<maven.compiler.source>21</maven.compiler.source>
|
|
<maven.compiler.target>21</maven.compiler.target>
|
|
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
|
|
<mainClass>me.sashegdev.zernmc.launcher.Main</mainClass>
|
|
</properties>
|
|
|
|
<dependencies>
|
|
<dependency>
|
|
<groupId>org.apache.httpcomponents</groupId>
|
|
<artifactId>httpclient</artifactId>
|
|
<version>4.5.14</version>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>com.fasterxml.jackson.core</groupId>
|
|
<artifactId>jackson-databind</artifactId>
|
|
<version>2.15.2</version>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>com.google.code.gson</groupId>
|
|
<artifactId>gson</artifactId>
|
|
<version>2.10.1</version>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>org.json</groupId>
|
|
<artifactId>json</artifactId>
|
|
<version>20231013</version>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>org.fusesource.jansi</groupId>
|
|
<artifactId>jansi</artifactId>
|
|
<version>2.4.1</version>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>me.tongfei</groupId>
|
|
<artifactId>progressbar</artifactId>
|
|
<version>0.9.5</version>
|
|
</dependency>
|
|
<dependency>
|
|
<groupId>commons-io</groupId>
|
|
<artifactId>commons-io</artifactId>
|
|
<version>2.15.1</version>
|
|
</dependency>
|
|
</dependencies>
|
|
|
|
<build>
|
|
<plugins>
|
|
<!-- Shade Plugin -->
|
|
<plugin>
|
|
<groupId>org.apache.maven.plugins</groupId>
|
|
<artifactId>maven-shade-plugin</artifactId>
|
|
<version>3.5.0</version>
|
|
<executions>
|
|
<execution>
|
|
<phase>package</phase>
|
|
<goals>
|
|
<goal>shade</goal>
|
|
</goals>
|
|
<configuration>
|
|
<outputFile>../server/builds/ZernMCLauncher.jar</outputFile>
|
|
<transformers>
|
|
<transformer implementation="org.apache.maven.plugins.shade.resource.ManifestResourceTransformer">
|
|
<mainClass>${mainClass}</mainClass>
|
|
<manifestEntries>
|
|
<Implementation-Version>${project.version}</Implementation-Version>
|
|
<Implementation-Title>ZernMC Launcher</Implementation-Title>
|
|
<Implementation-Vendor>SashegDev</Implementation-Vendor>
|
|
</manifestEntries>
|
|
</transformer>
|
|
</transformers>
|
|
</configuration>
|
|
</execution>
|
|
</executions>
|
|
</plugin>
|
|
|
|
<!-- Launch4j для создания .exe -->
|
|
<plugin>
|
|
<groupId>com.akathist.maven.plugins.launch4j</groupId>
|
|
<artifactId>launch4j-maven-plugin</artifactId>
|
|
<version>2.5.0</version>
|
|
<executions>
|
|
<execution>
|
|
<id>l4j</id>
|
|
<phase>package</phase>
|
|
<goals>
|
|
<goal>launch4j</goal>
|
|
</goals>
|
|
<configuration>
|
|
<outfile>../server/builds/ZernMCLauncher.exe</outfile>
|
|
<jar>../server/builds/ZernMCLauncher.jar</jar>
|
|
<headerType>console</headerType>
|
|
<dontWrapJar>false</dontWrapJar>
|
|
<jre>
|
|
<path>jre21</path>
|
|
<minVersion>21</minVersion>
|
|
</jre>
|
|
<versionInfo>
|
|
<fileVersion>1.0.0.0</fileVersion>
|
|
<txtFileVersion>1.0.0</txtFileVersion>
|
|
<fileDescription>ZernMC Launcher</fileDescription>
|
|
<productVersion>1.0.0.0</productVersion>
|
|
<txtProductVersion>1.0.0</txtProductVersion>
|
|
<productName>ZernMC Launcher</productName>
|
|
</versionInfo>
|
|
</configuration>
|
|
</execution>
|
|
</executions>
|
|
</plugin>
|
|
|
|
<!-- Antrun: копирование JRE и создание build.version + zip -->
|
|
<plugin>
|
|
<groupId>org.apache.maven.plugins</groupId>
|
|
<artifactId>maven-antrun-plugin</artifactId>
|
|
<version>3.1.0</version>
|
|
<executions>
|
|
<execution>
|
|
<phase>package</phase>
|
|
<goals><goal>run</goal></goals>
|
|
<configuration>
|
|
<target>
|
|
<echo file="../server/builds/build.version">${project.version}</echo>
|
|
|
|
<!-- Копируем JRE -->
|
|
<copy todir="../server/builds/jre21" overwrite="true">
|
|
<fileset dir="${user.home}/launcher/jre"/>
|
|
</copy>
|
|
|
|
<!-- Создаём zip -->
|
|
<zip destfile="../server/builds/ZernMCLauncher-${project.version}.zip"
|
|
basedir="../server/builds"
|
|
includes="ZernMCLauncher.exe,ZernMCLauncher.jar,build.version,jre21/**"/>
|
|
</target>
|
|
</configuration>
|
|
</execution>
|
|
</executions>
|
|
</plugin>
|
|
</plugins>
|
|
</build>
|
|
</project> |