Skip to content
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

Retrieve torrent files with a drag & drop #101

Open
devnoname120 opened this issue Aug 25, 2024 · 3 comments
Open

Retrieve torrent files with a drag & drop #101

devnoname120 opened this issue Aug 25, 2024 · 3 comments
Labels
enhancement New feature or request

Comments

@devnoname120
Copy link

devnoname120 commented Aug 25, 2024

transgui is very handy because it integrates well with the operating system and you can for example seamlessly drag & drop torrents from your computer to transgui.

One thing that transgui lacks however is the opposite action: easily copy the files of a finished torrent to my computer. Currently transgui requires users to mount the folder from their VPS themselves to access the files but this is pretty inconvenient (I only want it to be mounted when transgui is open), and requires to manually install an additional file server protocol (e.g. FTP or WebDAV) and then mount it manually.

For example flood.js implements this feature by providing the option to download a finished torrent as a ZIP in just a click. transgui could go a little further than that thanks to its Files tab and tight OS integration: users could easily drag & drop a folder or individual files right to their computer. This would make for a really great user experience IMO! Thanks

@lighterowl lighterowl added the enhancement New feature or request label Aug 26, 2024
@lighterowl
Copy link
Owner

lighterowl commented Aug 26, 2024

Hi there, thanks for the suggestion.

However, I'm afraid this is very out of scope of this project. The main reason for this is because supporting something like you're describing would require an extra piece of software to run on the host running the Transmission daemon anyway. If you have a look at the RPC specification, you will find no facilities that can be used for filesystem access at all. Personally, I consider this a good thing as I wouldn't want the RPC interface to allow any kind of access to the host's filesystem as I don't think there is any need to do that. I don't want transgui to require running any extra software other than the Transmission daemon, or a custom version of the daemon.

Flood can implement this because its backend acts as a proxy between the different torrent clients' RPC interfaces. The proxy's interface is thus different from the RPC interfaces of the native clients it supports and additional functionality can be added to the proxy if desired. As far as I'm aware, nor Transmission, nor qBt expose the ability to download the torrents' contents as ZIP in their RPC interfaces. Perhaps something could be hacked together with rTorrent as it permits executing arbitrary commands but even that sounds flaky at best.

Perhaps what you're describing could be implemented by allowing a transgui user to specify a custom command for copying a file or a folder, which would allow doing what you want - mount something, copy, and unmount. However, this not only sounds overly complicated (requiring users to have their own scripts for copying) but requires some kind of extra software running alongside the daemon anyway - in order to provide access to the files.

Let me know if you have some other idea for this that I may have missed.

@devnoname120
Copy link
Author

devnoname120 commented Sep 2, 2024

Thank you for your thoughtful reply. It makes a lot of sense. It indeed looks like an end-to-end solution would require running an additional service server-side.

As an alternative you could consider supporting rclone (it has a librclone library). Users could then configure a remote (sftp, ftp, ftps, ssh, SMB, rsync, etc. rclone supports 40+ remote types) and a base path for the mapping. As long as the user configures the remote properly the files can all be easily accessed through librclone without needing to mount anything. This would be handy because it's extremely likely that the user has access to these files already from one of the supported protocols.

It sounds like significant work (but not crazy either) and additional maintenance burden though.


Relatedly it seems that transgui doesn't support drag & dropping files to my computer even if the path mapping is set up and working (at least on macOS).

  • If I click on Open containing folder on a single-file torrent (audiobook.m4b) then it opens Finder on the directory of all completed files (in my case /mnt/torrents/completed) without highlighting the specific one that I was looking for, so I have to scan the list of files in the directory myself or use the search to find audiobook.m4b. It would be nice if it were highlighted in the Finder window that transgui opens.

  • If I click on Open instead then it opens the file with the default application. For example, if I click on Open for a torrent that just contains a single file audiobook.m4b then Books.app opens and imports the audiobook to the library.

All in all with a mapping defined I don't see an easy way to copy the output of a single-file torrent over, but I may have missed something.

Drag & drop would be a very welcome addition, even if it requires that users already have a properly configured mapping.

Let me know your thoughts!

@lighterowl
Copy link
Owner

As an alternative you could consider supporting rclone (it has a librclone library). Users could then configure a remote (sftp, ftp, ftps, ssh, SMB, rsync, etc. rclone supports 40+ remote types) and a base path for the mapping. As long as the user configures the remote properly the files can all be easily accessed through librclone without needing to mount anything. This would be handy because it's extremely likely that the user has access to these files already from one of the supported protocols.

This sounds like the perfect compromise. I can't promise that this is ever going to be implemented, of course, but I do like the idea.

If I click on Open containing folder on a single-file torrent (audiobook.m4b) then it opens Finder on the directory of all completed files (in my case /mnt/torrents/completed) without highlighting the specific one that I was looking for, so I have to scan the list of files in the directory myself or use the search to find audiobook.m4b. It would be nice if it were highlighted in the Finder window that transgui opens.

It's never bothered me personally (maybe my folders are just smaller) but that does sound like a bug. There's just no reason why this shouldn't be done.

If I click on Open instead then it opens the file with the default application. For example, if I click on Open for a torrent that just contains a single file audiobook.m4b then Books.app opens and imports the audiobook to the library.

And that's ... bad? I find this very useful.

All in all with a mapping defined I don't see an easy way to copy the output of a single-file torrent over, but I may have missed something.
Drag & drop would be a very welcome addition, even if it requires that users already have a properly configured mapping.

No, you haven't missed anything - this is not supported/implemented at all. The only available drag/drop behaviour is dropping .torrent files on the transgui main window, which causes it to add them.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants