-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
sqlx mig run ignores symlinks #614
Comments
tgeoghegan
added a commit
to tgeoghegan/sqlx
that referenced
this issue
Apr 5, 2023
When enumerating the source directory seeking migration files, `sqlx` ignores entries that aren't files. This was previously reported as launchbadge#614 and fixed in launchbadge#985 but apparently regressed somewhere along the way. This commit reintroduces the fix from launchbadge#985 to the current implementation: use `std::fs::metadata` instead of `std::fs::DirEntry::metadata`. The former is documented to traverse symlinks; the latter does not.
abonander
pushed a commit
that referenced
this issue
Jun 13, 2023
* Traverse symlinks when resolving migrations When enumerating the source directory seeking migration files, `sqlx` ignores entries that aren't files. This was previously reported as #614 and fixed in #985 but apparently regressed somewhere along the way. This commit reintroduces the fix from #985 to the current implementation: use `std::fs::metadata` instead of `std::fs::DirEntry::metadata`. The former is documented to traverse symlinks; the latter does not. * add migrations_symlink test
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
I tried this:
to be able to run up migrations with sqlx now but keep down migrations around for when sqlx supports them.
Unfortunately this doesn't work because the migrator ignores non-regular files.
The text was updated successfully, but these errors were encountered: