From 9a69ce23915e1219e4a85734cac1af71f23671a7 Mon Sep 17 00:00:00 2001 From: Athan Reines Date: Sat, 25 Nov 2023 14:27:44 -0800 Subject: [PATCH] fix: update grep path to lint both declaration and test files --- tools/git/hooks/pre-commit | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/git/hooks/pre-commit b/tools/git/hooks/pre-commit index a6500093bfe..78b6be8951c 100644 --- a/tools/git/hooks/pre-commit +++ b/tools/git/hooks/pre-commit @@ -354,7 +354,7 @@ run_lint() { fi # Lint TypeScript declaration files... if [[ -z "${skip_typescript_declarations}" ]]; then - files=$(echo "${changed_files}" | grep '\.d\.ts$' | tr '\n' ' ') + files=$(echo "${changed_files}" | grep '/docs/types/.*\.ts$' | tr '\n' ' ') if [[ -n "${files}" ]]; then make TYPESCRIPT_DECLARATIONS_LINTER=eslint FILES="${files}" lint-typescript-declarations-files > /dev/null >&2 if [[ "$?" -ne 0 ]]; then