What's new

Entware-ng for arm, mipsel ....

  • SNBForums Code of Conduct

    SNBForums is a community for everyone, no matter what their level of experience.

    Please be tolerant and patient of others, especially newcomers. We are all here to share and learn!

    The rules are simple: Be patient, be nice, be helpful or be gone!

Hi,

Please, there is any other alternatives to feed add_trackers.sh from another site?

Thanks!
 
Hi,

I think I have found something but I will need some help.
Most grateful for any ideas on where I went wrong.

Thank you!

Starting from this example:
https://torrents.me/s/45321e951bfa2dbd3e179f996f8275317bc7ccb6:torrentz2/

I have modified thees lines from:
Code:
base_url='https://torrentz2.eu'
announce_list=$(wget --no-check-certificate -qO - "${base_url}"/"${torrent_hash}" | grep -Eo "${pattern}")
for tracker in $(wget --no-check-certificate -qO - "${base_url}"/"${announce_list}") ; do
to
Code:
base_url='https://torrents.me/s'
announce_list=$(wget --no-check-certificate -qO - "${base_url}"/"${torrent_hash}":torrentz2/ | grep -Eo "${pattern}")
for tracker in $(wget --no-check-certificate -qO - "${base_url}"/"${announce_list}":torrentz2/) ; do
And added: echo "${base_url}"/"${torrent_hash}":torrentz2/ like this:
Code:
    if [ -z "$announce_list" ] ; then
        echo 'No additional trackers found, sorry.'
        echo "${base_url}"/"${torrent_hash}":torrentz2/
        return
    fi
So my entire script is now:
Code:
#!/bin/sh
#https://github.com/DontBeAPadavan/add_trackers/blob/master/add_trackers.sh
# Get transmission credentials
auth='user:pass'

add_trackers () {
    torrent_hash=$1
    #orig: base_url='https://torrentz2.eu'
    base_url='https://torrents.me/s'
    pattern='announcelist_[0-9]+'

    #orig: announce_list=$(wget --no-check-certificate -qO - "${base_url}"/"${torrent_hash}" | grep -Eo "${pattern}")
    announce_list=$(wget --no-check-certificate -qO - "${base_url}"/"${torrent_hash}":torrentz2/ | grep -Eo "${pattern}")

    if [ -z "$announce_list" ] ; then
        echo 'No additional trackers found, sorry.'
        echo "${base_url}"/"${torrent_hash}":torrentz2/
        return
    fi

    echo "adding trackers for $torrent_hash..."

    #orig: for tracker in $(wget --no-check-certificate -qO - "${base_url}"/"${announce_list}") ; do
    for tracker in $(wget --no-check-certificate -qO - "${base_url}"/"${announce_list}":torrentz2/) ; do
        echo -n "* ${tracker}..."
        if transmission-remote  --auth="$auth" --torrent "${torrent_hash}" -td "${tracker}" | grep -q 'success'; then
            echo ' failed.'
        else
            echo ' done.'
        fi
    done
}

# Get list of active torrents
ids="$(transmission-remote --auth="$auth" --list | grep -vE 'Seeding|Stopped|Finished' | grep '^ ' | awk '{ print $1 }')"

for id in $ids ; do
    echo "Processing torrent #$id..."
    hash="$(transmission-remote --auth="$auth"  --torrent "$id" --info | grep '^  Hash: ' | awk '{ print $2 }')"
    add_trackers "$hash"
done

And downloaded a torrent file and before put it into the transmission I edited the file using http://torrenteditor.com/ and hoped that after put the modified file into transmission it would work. But the output was:
Code:
Processing torrent #xx...
https://torrents.me/s/45321e951bfa2dbd3e179f996f8275317bc7ccb6:torrentz2/
No additional trackers found, sorry.
 
Hi all,

Still searching. I found https://torrentz.io/ and I am trying with it, but did not manage to do it until now.
I will share here if I will found a fix.

Merry Christmas and Happy New Year!
 

Support SNBForums w/ Amazon

If you'd like to support SNBForums, just use this link and buy anything on Amazon. Thanks!

Sign Up For SNBForums Daily Digest

Get an update of what's new every day delivered to your mailbox. Sign up here!

Staff online

Top