guh
This commit is contained in:
parent
47f5033687
commit
7b8b80be9f
1 changed files with 3 additions and 2 deletions
|
@ -2,6 +2,7 @@
|
|||
|
||||
add_trackers() {
|
||||
torrent_hash=$1
|
||||
torrent_name=$2
|
||||
id=$2
|
||||
for base_url in "$TORRENTLIST"; do
|
||||
if [ ! -f /tmp/trackers.txt ]; then
|
||||
|
@ -24,7 +25,7 @@ add_trackers() {
|
|||
fi
|
||||
|
||||
echo "URL for ${base_url}"
|
||||
echo "Adding trackers for $torrent_name..."
|
||||
echo "Adding trackers for $torrent_name ($torrent_hash)"
|
||||
|
||||
for tracker in $(cat /tmp/trackers.txt); do
|
||||
echo -n "${tracker}..."
|
||||
|
@ -47,7 +48,7 @@ while true; do
|
|||
if [ ! -f /tmp/TTAA.$id.lock ]; then
|
||||
hash="$(transmission-remote "$HOSTPORT" --authenv --torrent "$id" --info | grep '^ Hash: ' | awk '{ print $2 }')"
|
||||
torrent_name="$(transmission-remote "$HOSTPORT" --authenv --torrent "$id" --info | grep '^ Name: ' | cut -c 9-)"
|
||||
add_trackers "$hash" "$id" &
|
||||
add_trackers "$hash" "$torrent_name" "$id" &
|
||||
touch /tmp/TTAA.$id.lock
|
||||
fi
|
||||
done
|
||||
|
|
Loading…
Add table
Reference in a new issue