From 9beb09a33a893d3d3edc04188fceea9ea38e7053 Mon Sep 17 00:00:00 2001 From: san7890 Date: Sun, 22 Jan 2023 15:00:16 -0700 Subject: [PATCH] Adds Lint Against Non-TXT UpdatePaths Scripts (#72785) Prevents Regression Found In #72779 (someone putting an UpdatePaths script that doesn't end in .txt through) from happening again. --- tools/ci/check_grep.sh | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/tools/ci/check_grep.sh b/tools/ci/check_grep.sh index 6b9af2b671c..42082a5dc52 100644 --- a/tools/ci/check_grep.sh +++ b/tools/ci/check_grep.sh @@ -173,6 +173,14 @@ do done < <(jq -r '[.map_file] | flatten | .[]' $json) done +part "updatepaths validity" +lines=$(find tools/UpdatePaths/Scripts -type f ! -name "*.txt" | wc -l) +if [ $lines -gt 0 ]; then + echo + echo -e "${RED}ERROR: Found an UpdatePaths File that doesn't end in .txt! Please add the proper file extension!${NC}" + st=1 +fi; + section "515 Proc Syntax" part "proc ref syntax" if $grep '\.proc/' $code_x_515 ; then