From a14e71ad3d1e004c0f3a9f6a97f416ed841a2f1d Mon Sep 17 00:00:00 2001 From: Benjamin Bouvier Date: Wed, 25 Sep 2024 08:58:09 +0200 Subject: [PATCH] Don't search in ignored files by default Fixes #136. --- src/main.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/main.rs b/src/main.rs index 57ce472..3eb9eb3 100644 --- a/src/main.rs +++ b/src/main.rs @@ -45,9 +45,9 @@ struct MacheteArgs { #[argh(switch)] fix: bool, - /// respect ignore files (.gitignore, .ignore, etc.) when searching for files. + /// also search in ignored files (.gitignore, .ignore, etc.) when searching for files. #[argh(switch)] - ignore: bool, + no_ignore: bool, /// print version. #[argh(switch)] @@ -138,7 +138,7 @@ fn run_machete() -> anyhow::Result { &path, CollectPathOptions { skip_target_dir: args.skip_target_dir, - respect_ignore_files: args.ignore, + respect_ignore_files: !args.no_ignore, }, ) { Ok(entries) => entries,