【发布时间】:2020-05-14 16:11:13
【问题描述】:
我使用Husky 在提交文件之前检查文件。
但今天突然遇到了一些奇怪的问题,如下所示
╰─ node_modules/husky/run.js pre-commit husky > pre-commit (node v10.15.0) ↓ Stashing changes... [skipped]
→ No partially staged files found... ❯ Running tasks...
❯ Running tasks for {src}/**/*.{js,ts}
✖ tslint -c tslint.json
git add
⚠ tslint -c tslint.json was terminated with SIGABRT
husky > pre-commit hook failed (add --no-verify to bypass).
我尝试了谷歌和许多 StackOverflow 链接,但没有运气。任何帮助表示赞赏。
【问题讨论】:
-
这与 Git 无关。中止信号可以来自不同的点,但最常见的情况是自检。因此
tslint ... was terminated with SIGABRT表示tslint未能通过一些内部自检并停止(大概是为了避免损坏东西)。你会想看看 tslint 在做什么。
标签: git tslint husky git-husky