Pull git commit id once only - should improve build time

This commit is contained in:
Luck 2017-01-26 13:55:06 +00:00
parent 86b203c21b
commit f27034bb35
No known key found for this signature in database
GPG Key ID: EFA9B3EC5FD90F8B
8 changed files with 35 additions and 79 deletions

View File

@ -12,7 +12,7 @@
<artifactId>luckperms-bukkit-legacy</artifactId>
<build>
<defaultGoal>clean package</defaultGoal>
<finalName>LuckPerms-Bukkit-Legacy-${release.version}.${git.closest.tag.commit.count}</finalName>
<finalName>LuckPerms-Bukkit-Legacy-${release.version}.${patch.version}</finalName>
<resources>
<resource>
<directory>src/main/resources</directory>
@ -48,11 +48,7 @@
</goals>
<configuration>
<minimizeJar>false</minimizeJar>
<artifactSet>
<excludes>
<exclude>org.xerial:*</exclude>
</excludes>
</artifactSet>
<createDependencyReducedPom>false</createDependencyReducedPom>
<relocations>
<relocation>
<pattern>com.google.common</pattern>
@ -71,21 +67,6 @@
</execution>
</executions>
</plugin>
<plugin>
<groupId>pl.project13.maven</groupId>
<artifactId>git-commit-id-plugin</artifactId>
<version>2.2.1</version>
<executions>
<execution>
<goals>
<goal>revision</goal>
</goals>
</execution>
</executions>
<configuration>
<injectAllReactorProjects>true</injectAllReactorProjects>
</configuration>
</plugin>
</plugins>
</build>

View File

@ -14,7 +14,7 @@
<build>
<defaultGoal>clean package</defaultGoal>
<finalName>LuckPerms-Bukkit-${release.version}.${git.closest.tag.commit.count}</finalName>
<finalName>LuckPerms-Bukkit-${release.version}.${patch.version}</finalName>
<sourceDirectory>${basedir}/src/main/java</sourceDirectory>
<resources>
<resource>
@ -51,6 +51,7 @@
</goals>
<configuration>
<minimizeJar>false</minimizeJar>
<createDependencyReducedPom>false</createDependencyReducedPom>
<relocations>
<relocation>
<pattern>io.github.mkremins.fanciful</pattern>
@ -61,21 +62,6 @@
</execution>
</executions>
</plugin>
<plugin>
<groupId>pl.project13.maven</groupId>
<artifactId>git-commit-id-plugin</artifactId>
<version>2.2.1</version>
<executions>
<execution>
<goals>
<goal>revision</goal>
</goals>
</execution>
</executions>
<configuration>
<injectAllReactorProjects>true</injectAllReactorProjects>
</configuration>
</plugin>
</plugins>
</build>

View File

@ -1,5 +1,5 @@
name: LuckPerms
version: ${release.version}.${git.closest.tag.commit.count}
version: ${release.version}.${patch.version}
description: A permissions plugin
author: Luck
website: https://github.com/lucko/LuckPerms

View File

@ -14,7 +14,7 @@
<build>
<defaultGoal>clean package</defaultGoal>
<finalName>LuckPerms-Bungee-${release.version}.${git.closest.tag.commit.count}</finalName>
<finalName>LuckPerms-Bungee-${release.version}.${patch.version}</finalName>
<sourceDirectory>${basedir}/src/main/java</sourceDirectory>
<resources>
<resource>
@ -51,6 +51,7 @@
</goals>
<configuration>
<minimizeJar>false</minimizeJar>
<createDependencyReducedPom>false</createDependencyReducedPom>
<relocations>
<relocation>
<pattern>io.github.mkremins.fanciful</pattern>
@ -61,21 +62,6 @@
</execution>
</executions>
</plugin>
<plugin>
<groupId>pl.project13.maven</groupId>
<artifactId>git-commit-id-plugin</artifactId>
<version>2.2.1</version>
<executions>
<execution>
<goals>
<goal>revision</goal>
</goals>
</execution>
</executions>
<configuration>
<injectAllReactorProjects>true</injectAllReactorProjects>
</configuration>
</plugin>
</plugins>
</build>

View File

@ -1,5 +1,5 @@
name: LuckPerms
version: ${release.version}.${git.closest.tag.commit.count}
version: ${release.version}.${patch.version}
description: A permissions plugin
author: Luck
main: me.lucko.luckperms.bungee.LPBungeePlugin

24
pom.xml
View File

@ -39,6 +39,7 @@
<properties>
<project.build.sourceEncoding>UTF-8</project.build.sourceEncoding>
<release.version>2.17</release.version>
<patch.version>${git.closest.tag.commit.count}</patch.version>
</properties>
<distributionManagement>
@ -52,6 +53,29 @@
</repository>
</distributionManagement>
<build>
<plugins>
<plugin>
<groupId>pl.project13.maven</groupId>
<artifactId>git-commit-id-plugin</artifactId>
<version>2.2.1</version>
<executions>
<execution>
<phase>validate</phase>
<goals>
<goal>revision</goal>
</goals>
</execution>
</executions>
<configuration>
<skipPoms>false</skipPoms>
<injectAllReactorProjects>true</injectAllReactorProjects>
<runOnlyOnce>true</runOnlyOnce>
</configuration>
</plugin>
</plugins>
</build>
<repositories>
<repository>
<id>spigot-repo</id>

View File

@ -14,7 +14,7 @@
<build>
<defaultGoal>clean package</defaultGoal>
<finalName>LuckPerms-Sponge-${release.version}.${git.closest.tag.commit.count}</finalName>
<finalName>LuckPerms-Sponge-${release.version}.${patch.version}</finalName>
<sourceDirectory>${basedir}/src/main/java</sourceDirectory>
<resources>
<resource>
@ -51,13 +51,7 @@
</goals>
<configuration>
<minimizeJar>false</minimizeJar>
<artifactSet>
<excludes>
<exclude>org.slf4j:*</exclude>
<exclude>org.xerial:*</exclude>
<exclude>com.h2database:*</exclude>
</excludes>
</artifactSet>
<createDependencyReducedPom>false</createDependencyReducedPom>
<relocations>
<relocation>
<pattern>io.github.mkremins.fanciful</pattern>
@ -81,21 +75,6 @@
</execution>
</executions>
</plugin>
<plugin>
<groupId>pl.project13.maven</groupId>
<artifactId>git-commit-id-plugin</artifactId>
<version>2.2.1</version>
<executions>
<execution>
<goals>
<goal>revision</goal>
</goals>
</execution>
</executions>
<configuration>
<injectAllReactorProjects>true</injectAllReactorProjects>
</configuration>
</plugin>
</plugins>
</build>

View File

@ -24,6 +24,6 @@ package me.lucko.luckperms.sponge.utils;
public class VersionData {
public static final String VERSION = "${release.version}.${git.closest.tag.commit.count}";
public static final String VERSION = "${release.version}.${patch.version}";
}