From 05c8153b1abe40ed652e10f050b7950766adbff4 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Rafa=C5=82=20Mikrut?= Date: Wed, 23 Dec 2020 22:17:04 +0100 Subject: [PATCH] Add more default excluded items --- czkawka_core/src/common_items.rs | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) diff --git a/czkawka_core/src/common_items.rs b/czkawka_core/src/common_items.rs index 1d946f4..2514c73 100644 --- a/czkawka_core/src/common_items.rs +++ b/czkawka_core/src/common_items.rs @@ -32,8 +32,12 @@ impl ExcludedItems { continue; } if expression == "DEFAULT" { - // TODO add more files by default - checked_expressions.push("*/.git/*".to_string()); + if cfg!(target_family = "unix") { + checked_expressions.push("*/.git/*,*/node_modules/*,*/lost+found/*,*/Trash/*,*/.Trash-*/*,*/snap/*".to_string()); + } + if cfg!(target_family = "windows") { + checked_expressions.push("*/.git/*,*/node_modules/*,*/lost+found/*,*:/windows/*".to_string()); + } continue; } if !expression.contains('*') {