1
0
Fork 0
mirror of https://github.com/archtechx/todo-system.git synced 2025-12-12 09:04:03 +00:00

add todos_path and readme_path to excludes to avoid double counting priority todos

This commit is contained in:
Samuel Štancl 2023-11-23 17:05:51 +01:00
parent b5bbe710ff
commit 887199995a
2 changed files with 27 additions and 18 deletions

View file

@ -45,6 +45,7 @@ fn clean_line<'a>(line: &'a str, delimiter_word: &str) -> &'a str {
.trim()
.trim_end_matches("*/")
.trim_end_matches("-->")
.trim_end_matches("--}}")
.trim();
}
@ -128,13 +129,13 @@ pub fn scan_dir(path: &Path, entries: &mut Vec<Entry>, excludes: &Vec<PathBuf>,
continue;
}
if path.is_dir() {
for exclude in excludes {
if path == *exclude {
continue 'entry;
}
for exclude in excludes {
if path == *exclude {
continue 'entry;
}
}
if path.is_dir() {
scan_dir(path.as_path(), entries, excludes, stats)?
} else {
stats.visited_files += 1;