fix: skip node_modules in updater markdown and shell scans (#309)

update.sh's .md and .sh scan loops lacked the -not -path "*/node_modules/*" exclusion that the .ts loop already had, causing spurious update failures for third-party node_modules files that aren't OAC-managed. Brings all three loops in line.

Verified the exclusion filters nested node_modules at any depth, not just top-level, and no tracked files live under any node_modules/ path.

Fixes #308.
This commit is contained in:
will 2026-07-15 07:52:54 +08:00 committed by GitHub
parent 38a80cfcd3
commit cde3efe56f
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -242,7 +242,7 @@ update_all_components() {
else else
failed=$((failed + 1)) failed=$((failed + 1))
fi fi
done < <(find "$install_dir" -name "*.md" -type f -print0) done < <(find "$install_dir" -name "*.md" -type f -not -path "*/node_modules/*" -print0)
# Update TypeScript files # Update TypeScript files
while IFS= read -r -d '' file; do while IFS= read -r -d '' file; do
@ -260,7 +260,7 @@ update_all_components() {
else else
failed=$((failed + 1)) failed=$((failed + 1))
fi fi
done < <(find "$install_dir" -name "*.sh" -type f -print0) done < <(find "$install_dir" -name "*.sh" -type f -not -path "*/node_modules/*" -print0)
print_info "Updated: $updated file(s), failed: $failed file(s)" print_info "Updated: $updated file(s), failed: $failed file(s)"
} }