Skip to content

Passing a directory to refinery_core::util::find_migration_files results in a warning log message even if it only contains migrations #406

@coltfred

Description

@coltfred

I have i directory structure such as:

migrations/foo
├── V1__init.sql
├── V2__colt.sql
└── V3__other_thing.sql

If I pass migrations/foo to util::find_migration_files it will print a warning saying that foo doesn't match the expected regular expression.

I think the fix could be as simple as adding min_depth(1) to the WalkDir::new(...) indicating that you don't want the root. A more robust solution would be to filter out all directories.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions