标签: npm tslint pre-commit-hook husky git-husky
我有一个命令来统计TSlint报告的错误数
tslint src/app/calculator.ts | wc -l
当错误数超过100时,我想使用pre-commit husky命令使提交失败。
"husky": { "hooks": { "pre-commit": "tslint src/app/calculator.ts | wc -l" } }