Skip to content

Instantly share code, notes, and snippets.

@piglovesyou
Created May 24, 2021 07:15
Show Gist options
  • Save piglovesyou/372a9eda01c397a6320880c0557a17ae to your computer and use it in GitHub Desktop.
Save piglovesyou/372a9eda01c397a6320880c0557a17ae to your computer and use it in GitHub Desktop.
Husky in Monorepo, but want to run only in a subdirectory
#!/bin/sh
if [ $GIT_PREFIX != "frontend*" ]; then
exit 0
fi
. "$(dirname "$0")/_/husky.sh"
cd frontend || exit
yarn lint-staged
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment