diff options
| author | Robert Günzler <r@gnzler.io> | 2026-02-23 14:17:53 +0100 |
|---|---|---|
| committer | Robert Günzler <r@gnzler.io> | 2026-02-23 14:17:53 +0100 |
| commit | 0e0098c021080e2fc9271334de2f29b397ac5f25 (patch) | |
| tree | f2fbba9a151ab3bbe2031cb160d70790c8bc8fd7 /bundles/bitfroest/files/qbapi | |
| parent | bbee9eb8f939ac71d864ec019e00987fc4a453aa (diff) | |
bitfroest: update
Signed-off-by: Robert Günzler <r@gnzler.io>
Diffstat (limited to 'bundles/bitfroest/files/qbapi')
| -rwxr-xr-x | bundles/bitfroest/files/qbapi | 7 |
1 files changed, 4 insertions, 3 deletions
diff --git a/bundles/bitfroest/files/qbapi b/bundles/bitfroest/files/qbapi index 89d328e..bed63ba 100755 --- a/bundles/bitfroest/files/qbapi +++ b/bundles/bitfroest/files/qbapi @@ -1,7 +1,8 @@ #!/bin/sh +[ -n "$DEBUG" ] && set -x set -eu -qb_host=https://porphyrion.feralhosting.com/kum4/qbittorrent +qb_host=https://poseidon.feralhosting.com/kum4/qbittorrent qb_user=kum4 qb_pass=${repo.vault.cmd("rbw get 6e66abae-094c-4c98-83ad-9b7bae3eb1b2")} qb_cookiejar=/dev/shm/qb.cookies @@ -17,7 +18,7 @@ do_login() { do_getnew() { curl -sS -b "$qb_cookiejar" \ "$qb_host/api/v2/torrents/info?filter=completed&sort=added_on&tag=" | - jq -rc '.[]|[.name,.content_path]|@tsv' + jq -rc '.[]|[.name,(if .root_path != "" then .root_path else .content_path end)]|@tsv' } do_markx() { @@ -34,7 +35,7 @@ do_markx() { } main() { - test -f "$qb_cookiejar" || do_login + rm -f "$qb_cookiejar" && do_login case "$1" in getnew) do_getnew ;; |