Include specified files, even if they lack a .py[i] extension (#238)

This commit is contained in:
Anders Kaseorg 2022-09-20 17:53:52 -07:00 committed by GitHub
parent 50ca0d7d0a
commit f7fc702b2c
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 2 deletions

View File

@ -107,8 +107,7 @@ pub fn iter_python_files<'a>(
})
.filter_map(|entry| entry.ok())
.filter(|entry| {
let path = entry.path();
is_included(path)
(entry.depth() == 0 && !entry.file_type().is_dir()) || is_included(entry.path())
})
}