Skip to content

Instantly share code, notes, and snippets.

@tomdavidson
Last active October 28, 2021 02:59
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save tomdavidson/f2ee653f9acbf83da7ec3f0857e16df4 to your computer and use it in GitHub Desktop.
Save tomdavidson/f2ee653f9acbf83da7ec3f0857e16df4 to your computer and use it in GitHub Desktop.
#!/usr/bin/env zx
const shellFiles = globby.globbySync(['**/*.sh', '**/*.bash'], { gitignore: true });
nothrow($`npx -y shellcheck -f diff ssa-pg/scripts/deploy-infra.sh | git apply`);
#!/usr/bin/env bash
find . -type f \( -name '*.sh' -o -name '*.bash' -o -name '*.ksh' \) \
-exec sh -c '
for f do
git check-ignore -q "$f" ||
printf %s"\n" "$f"
done
' find-sh {} + | xargs shellcheck
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment