[bugfix] Fix pre-commit hook cross-platform compatibility (#4643)

This commit is contained in:
Chenlei Hu
2025-08-01 18:43:44 -04:00
committed by GitHub
parent 47e1808861
commit d779df5f64

13
.husky/pre-commit Normal file → Executable file
View File

@@ -1,9 +1,4 @@
if [[ "$OS" == "Windows_NT" ]]; then
npx.cmd lint-staged
# Check for unused i18n keys in staged files
npx.cmd tsx scripts/check-unused-i18n-keys.ts
else
npx lint-staged
# Check for unused i18n keys in staged files
npx tsx scripts/check-unused-i18n-keys.ts
fi
#!/usr/bin/env bash
npx lint-staged
npx tsx scripts/check-unused-i18n-keys.ts