fedarovich / qbittorrent-cli

Command line interface for QBittorrent
MIT License
304 stars 16 forks source link

[help needed] How to match? Is there regex or wildcard characters? Missing documentation and options. Please help. #110

Open Atlntssplayer opened 2 months ago

Atlntssplayer commented 2 months ago

For days I've been looking for a tool that can help me. Almost everything pointed to qbittorrent-api written in python but writing scripts for that requires coding knowledge which I don't have.

Then finally I found this qbittorrent-cli command line tool which seemed promising.

I have thousands of torrents and thousands of trackers. Many of the trackers are found in many of the torrents. Many of the trackers are offline or non-existent and have been since years. I would like to be able to remove selected trackers from all of my torrents. For example remove all variations of rarbg.to and rarb.me and rarb.com trackers from all torrents.

I tried for a few hours with this tool to do that but could only achieve very partial success, like removing one specific tracker from one specific torrent.

I didn't find any information in the documentation about how to match things.

For example the word "all" works when I want to pause all torrents but does not work if I want to match all torrents for tracker deletion.

Specifying what trackers to delete is even more difficult as I was only able to remove trackers if I gave the exact url and only for one specific torrent matched by hash.

With more flexible matching I could remove tens of thousands of trackers from thousands of torrent in a few seconds.

I think with this tool I'm really close to be able to do that I just can't figure it out by myself.

I would really appreciate some help.

What matching options are present? Is there regex for example? Or a wildcard character like * ?

For example how could I match all these trackers for removal from all torrents without having to specify them exactly one by one?

udp://9.rarbg.to:2730/announce udp://9.rarbg.to:2740/announce udp://9.rarbg.to:2720/announce udp://9.rarbg.to:2710/announce udp://9.rarbg.me:2730/announce udp://9.rarbg.com:2740/announce

but not udp://tracker.therarbg.com:6969/announce (this one has the word rarbg in it but it's a working tracker and no need to remove)

I don't have coding knowledge so most I'm capable of doing is maybe some simple regex. Or with a wildcard character like the asterisk maybe I could do this to match all the rarbg trackers but not therarbg.com : udp://.rarbg.

If I can't match everything in one command that is not a problem. I can run the program 5 or 10 times to find everything but not knowing how to match all torrents prevented me from doing that.

Thank you for any tips!