Skip to content

Commit 55380e8

Browse files
author
Max Lapides
committed
even cleaner
1 parent 1c41e42 commit 55380e8

File tree

3 files changed

+3
-8
lines changed

3 files changed

+3
-8
lines changed

dist/index.js

+1-3
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/index.js.map

+1-1
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/main.ts

+1-4
Original file line numberDiff line numberDiff line change
@@ -58,14 +58,11 @@ async function getVersion(token: string): Promise<string> {
5858
await exec.exec('git', ['rev-parse', '--show-toplevel'], {
5959
listeners: {
6060
stdout: (data: Buffer) => {
61-
root += data.toString();
61+
root += data.toString().trim();
6262
},
6363
},
6464
});
6565

66-
// Remove trailing newline
67-
root = root.trim();
68-
6966
if (!root) {
7067
throw new Error('Failed to find the repository root.');
7168
}

0 commit comments

Comments
 (0)