Skip to content

🤯 LobeHub - Super-Agents on Your Team. Add super-agents to the chats your team already uses.They take on work by themselves and get better every week.

🔧 fix: update pre-commit hook to conditionally run type-check on dev and main branches

Innei01f927bf5ffd
diff --git a/.husky/pre-commit b/.husky/pre-commit
index b1c7670b7bf..67538d4f4af 100755
--- a/.husky/pre-commit
+++ b/.husky/pre-commit
@@ -1,2 +1,5 @@
-npm run type-check
+BRANCH=$(git branch --show-current)
+if [ "$BRANCH" = "dev" ] || [ "$BRANCH" = "main" ]; then
+ npm run type-check
+fi
npx --no-install lint-staged