Closed revam closed 3 months ago
Will this PR make it possible to have one source import folder and another destination import folder where the files don't get moved but linked or copied instead? If yes awesome. Does it work well enough to test it?
No. Copying isn't really a good idea anyway. If you want copies, then use a copy on complete script in your downloader. We can't implement hard linking because .net doesn't have an API for it. Shoko can move hard links if you make a hard link via a completion script in your downloader.
In case you didn't know @da3dsoul, i added and have tested adding hard linking support in this PR. They won't be made automatically by any renaming script, but it's possible to create them through the REST v3 API in this PR as of right now.
Also when hard linking (or just creating another location in general) then the two locations will automatically be excempt from auto deletion.
There are a few things to change up, so I've converted this PR to a draft for now, since I'm focusing on the other PR for adding TMDB support.
Will this PR make it possible to have one source import folder and another destination import folder where the files don't get moved but linked or copied instead? If yes awesome. Does it work well enough to test it?
While it might make that possible it won't make it possible with a traditional renamer, you would have to use the file events directly and also either use the REST api or reference the shoko dlls directly and not using the abstraction.
Closed by cfaffe5. And no. No Hard linking were added. Only the file relocation and renamer/renamer scripts.
I've tested the new file endpoints to a degree (on linux using sqlite), moving files around, renaming them, creating hard and soft copies, and squashed a few bugs while I was at it.
So this PR adds renaming to the v3 api, and cleans up the move/rename internals, adapts the v1 api to the new internals, among other things.