Skip to content
This repository has been archived by the owner on Apr 6, 2023. It is now read-only.

Commit

Permalink
chore: Migrate from husky v4 to v5
Browse files Browse the repository at this point in the history
  • Loading branch information
jpedroschmitz committed Feb 18, 2021
1 parent 93ea403 commit 3b78e97
Show file tree
Hide file tree
Showing 6 changed files with 21 additions and 7 deletions.
1 change: 1 addition & 0 deletions .husky/.gitignore
@@ -0,0 +1 @@
_
5 changes: 5 additions & 0 deletions .husky/commit-msg
@@ -0,0 +1,5 @@
#!/bin/sh
. "$(dirname "$0")/_/husky.sh"
. "$(dirname "$0")/common.sh"

yarn commitlint --edit $1
8 changes: 8 additions & 0 deletions .husky/common.sh
@@ -0,0 +1,8 @@
command_exists () {
command -v "$1" >/dev/null 2>&1
}

# Workaround for Windows 10, Git Bash and Yarn
if command_exists winpty && test -t 1; then
exec < /dev/tty
fi
5 changes: 5 additions & 0 deletions .husky/pre-commit
@@ -0,0 +1,5 @@
#!/bin/sh
. "$(dirname "$0")/_/husky.sh"
. "$(dirname "$0")/common.sh"

yarn lint-staged
6 changes: 0 additions & 6 deletions .huskyrc.json

This file was deleted.

3 changes: 2 additions & 1 deletion package.json
Expand Up @@ -24,7 +24,8 @@
"tsc": "tsc --skipLibCheck",
"prepublishOnly": "npm run test && npm run build",
"publish:canary": "lerna version prerelease --no-changelog --preid next",
"publish:stable": "lerna version --no-changelog"
"publish:stable": "lerna version --no-changelog",
"postinstall": "husky install"
},
"devDependencies": {
"@babel/core": "7.12.10",
Expand Down

0 comments on commit 3b78e97

Please sign in to comment.