Skip to content

Commit

Permalink
fix: linting bash files according to shfmt
Browse files Browse the repository at this point in the history
  • Loading branch information
egel committed Sep 14, 2024
1 parent 3d55a0a commit 4c233b8
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
.PHONY: lint_shellcheck
lint_shellcheck:
find . -type f -not -path "./uncommited/*" -a \( -iname "*.sh" -o -iname "*.tmux" \) | \
find . -type f -not -path "./uncommited/*" -a \( -iname "*.sh" \) | \
xargs -I % sh -c 'shellcheck %'

.PHONY: lint_shfmt
lint_shfmt:
find . -type f -not -path "./uncommited/*" -a \( -iname "*.sh" -o -iname "*.tmux" \) | \
xargs -I % sh -c 'shfmt -l -d %'
find . -type f -not -path "./uncommited/*" -a \( -iname "*.sh" \) | \
xargs -I % sh -c 'shfmt -i=2 -l -d -ln=bash %'

.PHONY: check_scripts
check_scripts: lint_shellcheck lint_shfmt

0 comments on commit 4c233b8

Please sign in to comment.