[Plugin] Don't add torrent name to path

Suggest, post, or discuss plugins for Deluge
mhertz
Moderator
Moderator
Posts: 2195
Joined: Wed Jan 22, 2014 5:05 am
Location: Denmark

Re: [Plugin] Don't add torrent name to path

Post by mhertz »

Not bothered by your posting in the least mate, thanks, but I don't think I can do that I'm affraid, sorry, since main author not even could himself and said was a byproduct of the functionality he added. I'll take a quick peek sometime anyways regardless and post an update if succeeding, but as said, honestly doubt it, so please don't hold your breath.
mhertz
Moderator
Moderator
Posts: 2195
Joined: Wed Jan 22, 2014 5:05 am
Location: Denmark

Re: [Plugin] Don't add torrent name to path

Post by mhertz »

Okay I looked at this, and added renaming torrent back to original name after the processing, to fix the bad names when selecting to strip folders in plugin.

Tested shortly to verify working.

NoFolder-0.2.egg
mombolut
New User
New User
Posts: 6
Joined: Mon Jun 07, 2021 6:53 pm

Re: [Plugin] Don't add torrent name to path

Post by mombolut »

Looks like this works perfectly!
Nice that this file works for Python 2.7 and 3.8, I appreciate that!
I only can repeat myself, a huge thank you!
mhertz
Moderator
Moderator
Posts: 2195
Joined: Wed Jan 22, 2014 5:05 am
Location: Denmark

Re: [Plugin] Don't add torrent name to path

Post by mhertz »

You're welcome mate and I appreciate your post :)

Sorry, it's a py3 plugin, and I just stripped the python version from filename to not need rename if having other python 3.x version than used here. I forgot I had made a python2-fallback deluge2 version also, previously in thread, so I'll update that also within a few days and make an edit to previous post with added link. Sorry for confusion, should have stipulated that in hindsight.
mombolut
New User
New User
Posts: 6
Joined: Mon Jun 07, 2021 6:53 pm

Re: [Plugin] Don't add torrent name to path

Post by mombolut »

But... the plugin works? NOW I'm confused :lol:
Your new file (MD5: d8a932b410c371c62e0e4cbee6b47097) is on my NAS (Deluge 2.0.3 Python 2.7) and on my Windows Thinclient (2.0.4 dev51 Python 3.9) and it works in the webui and the app.
mhertz
Moderator
Moderator
Posts: 2195
Joined: Wed Jan 22, 2014 5:05 am
Location: Denmark

Re: [Plugin] Don't add torrent name to path

Post by mhertz »

Lol, sorry for the confusion and of-course you're correct and just me being confused :)

I was actually currently in the process of diff'ing both extracted old plugins I just downloaded from here, to see what the differences where as couldn't remember, for making the new one, and likewise was confused about there being none, so why I initially posted two versions was totally redundant lol. So only difference was that I initially built python2 plugin with the python2 version of python-setuptools(python2-setuptools) and the python3 plugin with python3 version of python-setuptools, but seemingly that is totally irrelevant, as long as no python 2 or 3 specific code anywhere seemingly, and that I remove the hardcoded python-version from filename, as deluge checks this also, if there.

Thanks for posting mate :)
mombolut
New User
New User
Posts: 6
Joined: Mon Jun 07, 2021 6:53 pm

Re: [Plugin] Don't add torrent name to path

Post by mombolut »

Ah ok! Nice to know!
Thank you for making this now (for my uses) a really nice plugin! :)
dixen64
New User
New User
Posts: 6
Joined: Mon May 02, 2022 6:25 am

Re: [Plugin] Don't add torrent name to path

Post by dixen64 »

I was wondering if anyone knew how to configure the plugin through the web ui? I'm not sure if there is a config file that could be edited from the command line.
mhertz
Moderator
Moderator
Posts: 2195
Joined: Wed Jan 22, 2014 5:05 am
Location: Denmark

Re: [Plugin] Don't add torrent name to path

Post by mhertz »

Yes, as you stated you need manually edit the auto-generated config-file 'nofolder.conf' in deluge profile dir, with deluge closed. It has two disabled options by default, which you can change from 'False' to 'True' for enabling.

Code: Select all

 
"dontaddfolder": False,
"createfolder": False,

The names of these are pretty self-explanatory I.e first option omits generating folders for multi-file torrents, while second option does the reverse I.e generates folders for single-file torrents.

You can as you stated edit the config-file from command line(terminal) if wanted, e.g through vim, vi or nano etc, or from GUI text-editor if preferred, just remember having deluge stopped while editing. Your deluge profile-dir holding that file is usually under either of these locations following, where the last one is the arch-linux default location(when started from systemd), which your forum-profile here suggests you're using.

Code: Select all

 
/var/lib/deluge/.config/deluge
~/.config/deluge 
/srv/deluge/.config/deluge
dixen64
New User
New User
Posts: 6
Joined: Mon May 02, 2022 6:25 am

Re: [Plugin] Don't add torrent name to path

Post by dixen64 »

mhertz wrote: Mon May 02, 2022 10:32 am Yes, as you stated you need manually edit the auto-generated config-file 'nofolder.conf' in deluge profile dir, with deluge closed. It has two disabled options by default, which you can change from 'False' to 'True' for enabling.

Code: Select all

 
"dontaddfolder": False,
"createfolder": False,

The names of these are pretty self-explanatory I.e first option omits generating folders for multi-file torrents, while second option does the reverse I.e generates folders for single-file torrents.

You can as you stated edit the config-file from command line(terminal) if wanted, e.g through vim, vi or nano etc, or from GUI text-editor if preferred, just remember having deluge stopped while editing. Your deluge profile-dir holding that file is usually under either of these locations following, where the last one is the arch-linux default location(when started from systemd), which your forum-profile here suggests you're using.

Code: Select all

 
/var/lib/deluge/.config/deluge
~/.config/deluge 
/srv/deluge/.config/deluge
Thank you very much for the help. To be more precise, I am running deluge in the delugevpn docker container which uses Arch as the os. I couldn't find nofolder.conf, so I checked the logs and saw that the conf file was not auto generated. I tried making a .conf file where I just copied and pasted the two lines you had shown, but it is not working since, I assume, there is more to the .conf file. Is there any way to give the entire file?
Post Reply