Skip to main content

has_exclude_pattern

Function has_exclude_pattern 

Source
pub fn has_exclude_pattern(existing: &[String], pattern: &str) -> bool
Expand description

Return true when existing already contains pattern after normalization.

ยงExamples

use tokmd_exclude::has_exclude_pattern;

let existing = vec!["out/bundle".to_string()];
assert!(has_exclude_pattern(&existing, "./out/bundle"));
assert!(!has_exclude_pattern(&existing, "dist/app"));