Update 91-qbittorrent_configuration.sh

This commit is contained in:
Alexandre
2023-02-27 23:46:02 +01:00
committed by GitHub
parent 9d963ad508
commit b71ad12ad8

View File

@@ -44,12 +44,12 @@ if bashio::config.has_value 'SavePath'; then
# Replace save path
CURRENTSAVEPATH=$(sed -n '/Downloads\\\SavePath/p' qBittorrent.conf)
sed -i "s|${CURRENTSAVEPATH#*=}|$DOWNLOADS|g" qBittorrent.conf || \
sed -i "s=${CURRENTSAVEPATH#*=}=$DOWNLOADS=g" qBittorrent.conf || \
sed -i "${LINE}a Downloads\\\SavePath=$DOWNLOADS" qBittorrent.conf
# Replace session save path
CURRENTSAVEPATH=$(sed -n '/Session\\\DefaultSavePath/p' qBittorrent.conf)
sed -i "s|${CURRENTSAVEPATH#*=}|$DOWNLOADS|g" qBittorrent.conf || \
sed -i "s=${CURRENTSAVEPATH#*=}=$DOWNLOADS=g" qBittorrent.conf || \
sed -i "2a Session\\\DefaultSavePath=$DOWNLOADS" qBittorrent.conf
# Info