Skip to content

Commit

Permalink
fix: skip reading ignored config dirs
Browse files Browse the repository at this point in the history
Fixes #3289
  • Loading branch information
jdx committed Dec 11, 2024
1 parent f808d12 commit 9f6ff2f
Showing 1 changed file with 11 additions and 4 deletions.
15 changes: 11 additions & 4 deletions src/config/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -768,10 +768,17 @@ pub fn load_config_paths(config_filenames: &[String], include_ignored: bool) ->
let mut config_files = dirs
.iter()
.flat_map(|dir| {
config_filenames
.iter()
.rev()
.flat_map(|f| glob(dir, f).unwrap_or_default().into_iter().rev())
if config_file::is_ignored(dir) {
vec![]
} else {
config_filenames
.iter()
.rev()
.flat_map(|f| glob(dir, f).unwrap_or_default())
.into_iter()
.rev()
.collect()
}
})
.collect_vec();

Expand Down

0 comments on commit 9f6ff2f

Please sign in to comment.