aboutsummaryrefslogtreecommitdiff
path: root/rescan-library.sh
blob: 230c78ba147c3564029fb69fe3df318932c66a39 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
#!/bin/sh
# File: rescan-library.sh
# Location: /mnt/public/Support/Programs/jellyfin/scripts/
# Author: bgstack15
# Startdate: 2024-01-20-7 13:09
# SPDX-License-Identifier: GPL-3.0-only
# Title: rescan-library utility for jellyfin
# Project: jellystack
# Purpose: oneliner to rescan a specific library so I don't have to navigate web ui
# History:
# Usage:
#    . /mnt/public/Support/Programs/jellyfin/scripts/autocmplete-rescan.bash
#    alias rescan-library=/mnt/public/Support/Programs/jellyfin/scripts/rescan-library.sh
#    rescan-library <TAB> for autocomplete
# Reference:
# Improve:
# Dependencies:
#    jellystack.py, jellystack_lib.py, python3
# Documentation:
. ~/.config/jellystack
test -z "${password}" && export password="example"
test -z "${username}" && export username="admin"
test -z "${server}"   && export server="http://example.com:8096" # omit the slash
executable="$( dirname "$( readlink -f "${0}" )" )/jellystack.py"
for word in "${@}" ;
do
   python3 "${executable}" --library "${word}"
done
bgstack15