From 8cfa8b7dab6ba925a73114c7ae0d5199f6fc6ca6 Mon Sep 17 00:00:00 2001 From: LagoLunatic Date: Sat, 23 Aug 2025 17:37:34 -0400 Subject: [PATCH] Update default watch patterns to include more extensions (#246) --- README.md | 8 +++++++- config.schema.json | 8 +++++++- objdiff-core/src/config/mod.rs | 5 +++-- 3 files changed, 17 insertions(+), 4 deletions(-) diff --git a/README.md b/README.md index c53d4b8..c9941fc 100644 --- a/README.md +++ b/README.md @@ -90,17 +90,23 @@ file as well. You can then add `objdiff.json` to your `.gitignore` to prevent it "build_base": true, "watch_patterns": [ "*.c", + "*.cc", "*.cp", "*.cpp", "*.cxx", + "*.c++", "*.h", + "*.hh", "*.hp", "*.hpp", "*.hxx", + "*.h++", + "*.pch", + "*.pch++", + "*.inc", "*.s", "*.S", "*.asm", - "*.inc", "*.py", "*.yml", "*.txt", diff --git a/config.schema.json b/config.schema.json index de97226..0d2f47e 100644 --- a/config.schema.json +++ b/config.schema.json @@ -57,17 +57,23 @@ }, "default": [ "*.c", + "*.cc", "*.cp", "*.cpp", "*.cxx", + "*.c++", "*.h", + "*.hh", "*.hp", "*.hpp", "*.hxx", + "*.h++", + "*.pch", + "*.pch++", + "*.inc", "*.s", "*.S", "*.asm", - "*.inc", "*.py", "*.yml", "*.txt", diff --git a/objdiff-core/src/config/mod.rs b/objdiff-core/src/config/mod.rs index bf953de..909365d 100644 --- a/objdiff-core/src/config/mod.rs +++ b/objdiff-core/src/config/mod.rs @@ -204,8 +204,9 @@ pub struct ScratchConfig { pub const CONFIG_FILENAMES: [&str; 3] = ["objdiff.json", "objdiff.yml", "objdiff.yaml"]; pub const DEFAULT_WATCH_PATTERNS: &[&str] = &[ - "*.c", "*.cp", "*.cpp", "*.cxx", "*.h", "*.hp", "*.hpp", "*.hxx", "*.s", "*.S", "*.asm", - "*.inc", "*.py", "*.yml", "*.txt", "*.json", + "*.c", "*.cc", "*.cp", "*.cpp", "*.cxx", "*.c++", "*.h", "*.hh", "*.hp", "*.hpp", "*.hxx", + "*.h++", "*.pch", "*.pch++", "*.inc", "*.s", "*.S", "*.asm", "*.py", "*.yml", "*.txt", + "*.json", ]; pub const DEFAULT_IGNORE_PATTERNS: &[&str] = &["build/**/*"];