build: add husky to automatically format code
- husky installs a git hook to run make format every time you commit new code - if `make format` fails (if a dependency is missing or prettier throws an error), the hook will still succeed as to not block people for dumb reasons - pin prettier and husky to 3.2.5 and 9.0.11 respectively - add prettier as a dependency for the `make format` rule
This commit is contained in:
@ -902,7 +902,7 @@ dist-test: dist
|
||||
@rm -rf tildefriends-$(VERSION_NUMBER)
|
||||
.PHONY: dist-test
|
||||
|
||||
format:
|
||||
format: prettier
|
||||
@clang-format -i $(wildcard src/*.c src/*.h src/*.m)
|
||||
.PHONY: format
|
||||
|
||||
|
Reference in New Issue
Block a user