tonikelope / megabasterd

Yet another unofficial (and ugly) cross-platform MEGA downloader/uploader/streaming suite.
GNU General Public License v3.0
4.43k stars 598 forks source link

Can't download folder specific link in share #582

Closed ghost closed 9 months ago

ghost commented 9 months ago

Sometimes people share huge collections in a single link, the root folder then has many many folders and files inside it. When you rightclick a subfolder and copy its specific link, MegaBastard throws away the reference to this subfolder, and tries to index and download the entire root folder, which in many of these huge terabyte collections will make the program freeze even before showing the content of the root folder.

example root folder: https://mega.nz/folder/YyNXmJQB#MHDC-bG0LWB-gpAp-zDvcw

now right click Subfolder 3 and copy its link: https://mega.nz/folder/YyNXmJQB#MHDC-bG0LWB-gpAp-zDvcw/folder/93lFULzY image

notice the suffix: /folder/93lFULzY image This is the part that refers to the specific folder inside of the main share root. This is the part that MegaBastard ignores (JDownloader for example is capable of targeting the specific folder)

Please make it so that these subfolder specific links actually work. It is impossible to wait for MegaBastard to show the content of these terabytes of huge collections and it is also impossible to find what you want through MegaBastard as on the mega website the web interface allows for searching through files and folder.

tonikelope commented 9 months ago

I have added support for such links. Basically what it will do is read the folder and automatically remove from the file tree everything but the chosen subfolder (clicking on RESTORE will load the FULL contents of the folder).

I hope it will be useful.

ghost commented 9 months ago

Thank you! I just tested it, and it works! Can you please make it so the parent folders are now re-made on download and only the linked folder and its subfolders are downloaded?

image for example, so that only the Close Up folder which was linked is downloaded and the folders inside it, but the parent folders are not re-created in the download target

tonikelope commented 9 months ago

Done