File tree Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Expand file tree Collapse file tree 1 file changed +4
-4
lines changed Original file line number Diff line number Diff line change @@ -355,6 +355,10 @@ impl<'cfg> PathSource<'cfg> {
355
355
if !is_root && fs:: metadata ( & path. join ( "Cargo.toml" ) ) . is_ok ( ) {
356
356
return Ok ( ( ) ) ;
357
357
}
358
+ // Skip dotfile directories.
359
+ if path. file_name ( ) . and_then ( |s| s. to_str ( ) ) . map ( |s| s. starts_with ( '.' ) ) == Some ( true ) {
360
+ return Ok ( ( ) ) ;
361
+ }
358
362
359
363
// For package integration tests, we need to sort the paths in a deterministic order to
360
364
// be able to match stdout warnings in the same order.
@@ -368,10 +372,6 @@ impl<'cfg> PathSource<'cfg> {
368
372
entries. sort_unstable_by ( |a, b| a. as_os_str ( ) . cmp ( b. as_os_str ( ) ) ) ;
369
373
for path in entries {
370
374
let name = path. file_name ( ) . and_then ( |s| s. to_str ( ) ) ;
371
- // Skip dotfile directories.
372
- if name. map ( |s| s. starts_with ( '.' ) ) == Some ( true ) {
373
- continue ;
374
- }
375
375
if is_root && name == Some ( "target" ) {
376
376
// Skip Cargo artifacts.
377
377
continue ;
You can’t perform that action at this time.
0 commit comments