mirror of
https://github.com/encounter/objdiff.git
synced 2025-12-11 06:27:55 +00:00
Add "ignore_patterns" option to config
This allows explicitly ignoring changes to certain files or directories, even if the changed file ends up matching `watch_patterns`. The default value, `build/**/*` will ensure that changes in the build directory will not trigger a duplicate rebuild. Resolves #143 Resolves #215
This commit is contained in:
@@ -342,10 +342,12 @@ fn run_interactive(
|
||||
};
|
||||
if let (Some(project_dir), Some(project_config)) = (&state.project_dir, &state.project_config) {
|
||||
let watch_patterns = project_config.build_watch_patterns()?;
|
||||
let ignore_patterns = project_config.build_ignore_patterns()?;
|
||||
state.watcher = Some(create_watcher(
|
||||
state.modified.clone(),
|
||||
project_dir.as_ref(),
|
||||
build_globset(&watch_patterns)?,
|
||||
build_globset(&ignore_patterns)?,
|
||||
Waker::from(state.waker.clone()),
|
||||
)?);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user