Skip to content

Commit

Permalink
fix for non interactive shell in IDE
Browse files Browse the repository at this point in the history
  • Loading branch information
Alexander Abroskin committed Dec 13, 2019
1 parent d9cd520 commit d79a3a4
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion cmd/add.go
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,9 @@ if [ "$LEFTHOOK" = "0" ]; then
exit 0
fi
exec < /dev/tty # <- enables interactive shell
if [ -t 1 ] ; then
exec < /dev/tty ; # <- enables interactive shell
fi
` + autoInstall(hookName, fs) + "\n" + "cmd=\"lefthook run " + hookName + " $@\"" +
`
Expand Down

0 comments on commit d79a3a4

Please sign in to comment.