我刚刚将 Angular 11 应用程序更新为 eslint 并安装了 commitizen、commitlint、husky 和语义发布,以通过 npm 和 Travis 驱动 CI。
我按照 Angular 推荐链接上的说明进行操作。
Linting 本身工作正常。
该问题出现在 commit-msg 挂钩中,但较早引起。
现在,当我运行时,npx git-cz
我得到了一组不同的“提交类型”类型。
我得到修复、更新、破坏、文档、构建、新建、升级。
以前我得到了 Angular 标准列表“feat、fix、docs、style、refactor、perf、test、ci、chore、revert”。
commit-msg 挂钩失败的原因有两个:
type must be lower-case
type must be one of [build, chore, ci, docs, feat, fix, perf, refactor, revert, style, test]
我花了几个小时阅读所有相关文档,但找不到如何将类型列表更改回原来的样子。
任何建议都会非常受欢迎。