diff --git a/Makefile b/Makefile new file mode 100644 index 000000000..ef15c9b57 --- /dev/null +++ b/Makefile @@ -0,0 +1,16 @@ +.PHONY: setup + +SHELL = bash + +all: setup + +setup: + command -v pre-commit > /dev/null && pre-commit install + +# https://google.github.io/styleguide/shellguide.html +shell-format: + shfmt -f . | xargs shfmt -i 2 -ci -sr -kp -w + +shell-check: + shfmt -f . | xargs shfmt -i 2 -ci -sr -kp -d + shfmt -f . | xargs shellcheck --color=always