Skip to content

Commit 75a5d1d

Browse files
authored
fix: Ignore stderr output from git command (#613)
1 parent b8b5b55 commit 75a5d1d

File tree

1 file changed

+4
-1
lines changed
  • packages/bundler-plugin-core/src

1 file changed

+4
-1
lines changed

packages/bundler-plugin-core/src/utils.ts

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -198,7 +198,10 @@ export function stringToUUID(str: string): string {
198198
function gitRevision(): string | undefined {
199199
let gitRevision: string | undefined;
200200
try {
201-
gitRevision = childProcess.execSync("git rev-parse HEAD").toString().trim();
201+
gitRevision = childProcess
202+
.execSync("git rev-parse HEAD", { stdio: ["ignore", "pipe", "ignore"] })
203+
.toString()
204+
.trim();
202205
} catch (e) {
203206
// noop
204207
}

0 commit comments

Comments
 (0)