feat(api): move title folders on root path change
Changing a root's path rewrote the row and moved nothing, so every title under it was mislocated at once. It now reuses the #228 mover: plan every rename, refuse a destination that already exists, rewrite the media_files rows in the same transaction as the row change. The move is all or nothing. A root row carries one path, so a half-moved library would have to describe both places; instead one folder that cannot move puts back the ones that already did and leaves the root's path alone, and the same request is the retry. just ci ran clean through the gate: 498 tests passed.
This commit is contained in:
@@ -505,7 +505,7 @@ Media kind first, hard audience boundary second, people nowhere.
|
||||
- **Release group is deliberately absent.** It is not a selection criterion and
|
||||
it makes filenames long enough to break a terminal.
|
||||
|
||||
Changing a title's root relocates its title folder into the new root; roots are assumed to share one filesystem, so the move is a rename, never a copy.
|
||||
Changing a title's root relocates its title folder into the new root; roots are assumed to share one filesystem, so the move is a rename, never a copy. Changing a root's path is the same move over every title under it, and it is all or nothing: one folder that cannot move puts back the ones that already did and leaves the root's path alone, so the stored path always describes the disk.
|
||||
|
||||
During transition, write into the existing roots so Jellyfin needs no
|
||||
reconfiguration and new content appears immediately. Radarr will not touch a
|
||||
|
||||
Reference in New Issue
Block a user