Skip to content

Commit

Permalink
Include build number/timestamp in plugin version
Browse files Browse the repository at this point in the history
This help extremely when debugging issues which users might have with dev builds/manually compiled ones.
  • Loading branch information
Phoenix616 committed Apr 12, 2020
1 parent 1a7b832 commit 57233f7
Show file tree
Hide file tree
Showing 2 changed files with 30 additions and 1 deletion.
29 changes: 29 additions & 0 deletions core/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,35 @@
<name>FactionsTop</name>
<description>An efficient and comprehensive factions ranking system.</description>

<properties>
<minecraft.plugin.version>${project.version} ${buildDescription}</minecraft.plugin.version>
</properties>

<profiles>
<profile>
<id>static_build_number</id>
<activation>
<property>
<name>!env.BUILD_NUMBER</name>
</property>
</activation>
<properties>
<buildDescription>(compiled at ${maven.build.timestamp})</buildDescription>
</properties>
</profile>
<profile>
<id>dynamic_build_number</id>
<activation>
<property>
<name>env.BUILD_NUMBER</name>
</property>
</activation>
<properties>
<buildDescription>(build ${env.BUILD_NUMBER})</buildDescription>
</properties>
</profile>
</profiles>

<build>
<plugins>
<plugin>
Expand Down
2 changes: 1 addition & 1 deletion core/src/main/resources/plugin.yml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
name: ${project.name}
main: net.novucs.ftop.FactionsTopPlugin
version: ${project.version}
version: '${minecraft.plugin.version}'
description: ${project.description}
author: novucs
softdepend: [EpicSpawners, Essentials, Factions, LegacyFactions, Vault, MVdWPlaceholderAPI, PlaceholderAPI]
Expand Down

0 comments on commit 57233f7

Please sign in to comment.