pub fn pack_aware_quick_reject(cmd: &str, enabled_keywords: &[&str]) -> boolExpand description
Pack-aware quick-reject filter.
Returns true if the command can be safely skipped (contains none of the provided keywords from enabled packs).
This is the correct function to use when non-core packs are enabled. It checks all keywords from enabled packs, not just “git” and “rm”.
§Performance
Uses SIMD-accelerated substring search via memchr as a fast prefilter, then applies token-aware checks inside executable spans (via context classification) to avoid substring false triggers.
§Arguments
cmd- The command string to checkenabled_keywords- Keywords from all enabled packs (fromPackRegistry::collect_enabled_keywords)
§Returns
true if the command contains NO keywords (safe to skip pack checking)
false if the command contains at least one keyword (must check packs)