Skip to content

Commit aa4d10e

Browse files
committed
Always return full path to git dir
1 parent 38fe875 commit aa4d10e

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/git-hooks.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,7 @@ function spawnHook(hookName, args) {
173173
*/
174174
function getClosestGitPath(currentPath) {
175175
try {
176-
var result = execSync('git rev-parse --git-dir', {cwd: currentPath}).toString();
176+
var result = execSync('git rev-parse --absolute-git-dir', {cwd: currentPath}).toString();
177177
return result.replace(/\n/g, '');
178178
} catch (error) {
179179
if (error.status === 128) {

0 commit comments

Comments
 (0)