From 684360aef3857dec6be94467f9eba5682cdf281e Mon Sep 17 00:00:00 2001 From: Krajmark Date: Sun, 13 Nov 2022 18:04:38 +0100 Subject: [PATCH] fix: git throws 128 error --- src/main/java/com/widen/versioning/VersionGenerator.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/main/java/com/widen/versioning/VersionGenerator.java b/src/main/java/com/widen/versioning/VersionGenerator.java index 323eb9a..e307199 100644 --- a/src/main/java/com/widen/versioning/VersionGenerator.java +++ b/src/main/java/com/widen/versioning/VersionGenerator.java @@ -58,7 +58,7 @@ public static Optional gitDescribe(Settings settings, File projectDir) { .redirectOutput(ProcessBuilder.Redirect.PIPE) .redirectError(ProcessBuilder.Redirect.INHERIT) .directory(projectDir); - processBuilder.environment().put("GIT_DIR", projectDir.getPath() + "/.git"); + processBuilder.environment().put("GIT_DIR", projectDir.getPath()); Process process = processBuilder.start(); String output = IOUtils.toString(process.getInputStream(), Charset.forName("UTF-8"));