Skip to content

Commit f229dfe

Browse files
committed
Always return full path to git dir
1 parent 5bcb7ca commit f229dfe

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

lib/git-hooks.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -179,7 +179,7 @@ function spawnHook(hookName, args) {
179179
*/
180180
function getClosestGitPath(currentPath) {
181181
try {
182-
var result = execSync('git rev-parse --git-dir', {cwd: currentPath}).toString();
182+
var result = execSync('git rev-parse --absolute-git-dir', {cwd: currentPath}).toString();
183183
return result.replace(/\n/g, '');
184184
} catch (error) {
185185
if (error.status === 128) {

0 commit comments

Comments
 (0)