From 6edc85b18efbd2d7fb5c1055ec8bc34c7e4e9d96 Mon Sep 17 00:00:00 2001
From: Braydon <32585528+Rainnny7@users.noreply.github.com>
Date: Sat, 11 Nov 2023 16:10:32 -0500
Subject: [PATCH] Reploy new ver
---
pom.xml | 2 +-
src/main/java/me/braydon/plugin/GitUtils.java | 6 +++---
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/pom.xml b/pom.xml
index cdac599..4ef77fb 100644
--- a/pom.xml
+++ b/pom.xml
@@ -7,7 +7,7 @@
Maven Git Versioning
me.braydon
git-versioning-maven-plugin
- 1.0
+ 1.0.2
maven-plugin
diff --git a/src/main/java/me/braydon/plugin/GitUtils.java b/src/main/java/me/braydon/plugin/GitUtils.java
index 3948004..90bd8e7 100644
--- a/src/main/java/me/braydon/plugin/GitUtils.java
+++ b/src/main/java/me/braydon/plugin/GitUtils.java
@@ -65,9 +65,7 @@ public final class GitUtils {
continue;
}
walk.dispose(); // Dispose of the rev walk
-
- // Return the git data
- return new AbstractMap.SimpleEntry<>(latestCommit.getName(), commitsSinceLastTag);
+ return new AbstractMap.SimpleEntry<>(latestCommit.getName(), commitsSinceLastTag); // Return the git data
}
commitsSinceLastTag++; // Increment commits since last tag
if (commit.getParentCount() > 0) { // Get the parent commit
@@ -76,6 +74,8 @@ public final class GitUtils {
break;
}
}
+ walk.dispose(); // Dispose of the rev walk
+ return new AbstractMap.SimpleEntry<>(latestCommit.getName(), commitsSinceLastTag); // Return the git data
} catch (IOException | GitAPIException ex) {
System.err.println("Failed fetching git data:");
ex.printStackTrace();