enforce absolute path for getGitPath
This commit is contained in:
parent
32ebc90995
commit
19f4e8dd3e
2
dist/index.js
vendored
2
dist/index.js
vendored
@ -831,7 +831,7 @@ class GitCommandManager {
|
||||
}
|
||||
getGitPath(path) {
|
||||
return __awaiter(this, void 0, void 0, function* () {
|
||||
const args = ['rev-parse', '--git-path'];
|
||||
const args = ['rev-parse', '--path-format=absolute', '--git-path'];
|
||||
if (path)
|
||||
args.push(path);
|
||||
const output = yield this.exec(args);
|
||||
|
||||
@ -147,7 +147,7 @@ export class GitCommandManager {
|
||||
}
|
||||
|
||||
async getGitPath(path?: string): Promise<string> {
|
||||
const args = ['rev-parse', '--git-path']
|
||||
const args = ['rev-parse', '--path-format=absolute', '--git-path']
|
||||
if (path) args.push(path)
|
||||
const output = await this.exec(args)
|
||||
return output.stdout.trim()
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user