diff --git a/.husky/commit-msg b/.husky/commit-msg old mode 100644 new mode 100755 index 7e9b3075ba8..df96e691d62 --- a/.husky/commit-msg +++ b/.husky/commit-msg @@ -1,17 +1,5 @@ #!/usr/bin/env sh . "$(dirname -- "$0")/_/husky.sh" -export NVM_DIR="$HOME/.nvm/nvm.sh" -if [ -f "$NVM_DIR" ]; then - . "$(dirname $NVM_DIR)/nvm.sh" - - export NVM_DIR="$HOME/.nvm" - a=$(nvm ls | grep 'node') - b=${a#*(-> } - v=${b%%[)| ]*} - - export PATH="$NVM_DIR/versions/node/$v/bin:$PATH" -fi - -npx --no -- commitlint --edit +npm run commitlint ${1} diff --git a/package.json b/package.json index ac62d1bfa47..163ce361275 100644 --- a/package.json +++ b/package.json @@ -33,7 +33,9 @@ "sync:pullMFTypes": "concurrently \"node ./packages/enhanced/pullts.js\"", "app:next:dev": "nx run-many --target=build --configuration=development -p enhanced utils nextjs-mf && nx run-many --target=serve --configuration=development -p 3000-home 3001-shop 3002-checkout", "app:next:prod": "nx run-many --target=build --configuration=production -p 3000-home 3001-shop 3002-checkout && nx run-many --target=serve --configuration=production -p 3000-home 3001-shop 3002-checkout", - "app:runtime:dev": "nx run-many --target=serve -p runtime_demo_host runtime_demo_remote" + "app:runtime:dev": "nx run-many --target=serve -p runtime_demo_host runtime_demo_remote", + "commitlint": "commitlint --edit", + "prepare": "husky install" }, "dependencies": { "adm-zip": "0.5.10",