Skip to content

Commit

Permalink
chore: correct husky output
Browse files Browse the repository at this point in the history
Git hooks output running using husky gives output as a plain text without animated log when npx lint-staged is used. A temporary fix of redirecting stdout and stderr taken from typicode/husky#968 (comment) works for the current version of husky and lint-staged.
  • Loading branch information
riuandg5 committed Aug 8, 2023
1 parent 0d60c37 commit 145923d
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 0 deletions.
2 changes: 2 additions & 0 deletions .husky/post-commit
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
#!/usr/bin/env sh
. "$(dirname -- "$0")/_/husky.sh"

exec >/dev/tty 2>&1

npm run release:check
2 changes: 2 additions & 0 deletions .husky/pre-commit
Original file line number Diff line number Diff line change
@@ -1,4 +1,6 @@
#!/usr/bin/env sh
. "$(dirname -- "$0")/_/husky.sh"

exec >/dev/tty 2>&1

npx lint-staged

0 comments on commit 145923d

Please sign in to comment.