This repository has no description
481 B
13 lines
1{ pkgs }:
2pkgs.writers.writeDashBin "dls" ''
3 set -efux
4 SESSION_ID=$(
5 curl -Ss -d '{}' http://yellow.r:9091/transmission/rpc -v -o /dev/null 2>&1 |
6 grep -oP '(?<=X-Transmission-Session-Id: )\w+'
7 )
8 ${pkgs.curl}/bin/curl -Ss \
9 http://yellow.r:9091/transmission/rpc \
10 -H "X-Transmission-Session-Id: $SESSION_ID" \
11 -d '{"arguments":{"fields":["errorString","eta","isFinished","name","sizeWhenDone","status"]},"method":"torrent-get","tag":4}' |
12 jq .
13''