Closed 0xisk closed 3 months ago
I am not sure why there are several conflicting changes, it does not seem that those are relevant to the git commit hooks as well.
I am not sure why there are several conflicting changes, it does not seem that those are relevant to the git commit hooks as well.
Its ready now, I have a comment on this feature though.
I searched for a tool for supporting git hooks without having to use NPM pack or JS/TS. I found only rusty-hook tool. but still what is missing is the commit-msg
linter hook which needs still I am thinking of a tool that does this already with Rust only. The way I used to do it before is using husky
with JS as you can see there:
That directly installs this commit lint package from npm @commitlint/config-conventional
, however in Rust I didn't find yet a similar tool. So the question now, if we are planning anyways to make this repo as a monorepo that means it would have at some point a TS package for the browser interface so maybe can we use this JS way directly from now, or?
Hey @0xisk, did you take a look on pre-commit? Would it work for Rust projects?
Hey @0xisk, did you take a look on pre-commit? Would it work for Rust projects?
I tied it out and it works now. Only the challenge I had was with commit-lint
the best way I found for this was to install @commitlint/cli @commitlint/config-conventional
globally via NPM
and then add the configurations in commitlint.config.js
script in the root. I tried to install the commitizen
as suggested in this article: https://rodneylab.com/rust-ci-tooling/ but I didn't find it easy to install that package easily in Arch Linux python-commitizen
, it would need a lot of dependencies so I thought the easier option is using JS for that.
This PR adds support for
pre-commit
andpre-push
git hooks using rusty-hook tool.Blocked by:
9