【git 实践】git hooks 实践

876 阅读1分钟

前端使用 githooks,一般利用 npm 工具,常用三个 npm 工具如下:

  • pre-commit
  • pre-push
  • husky

对于怎么使用,大家知识 npm 官网搜索对应的 npm 工具的首页,里面会有对应使用文档。

吐槽一下:** husky 工具有版本迭代,导致工具本身api没有向下兼容,为此我浪费一些时间**。