Update umlautadaptarr.sh

This commit is contained in:
elvito 2025-04-16 16:39:14 +02:00 committed by GitHub
parent 482fec9e95
commit bbdc62bbd4
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -29,11 +29,13 @@ function update_script() {
exit
fi
msg_info "Updating $APP..."
cd /opt/UmlautAdaptarr || exit
$STD git pull origin master
$STD dotnet restore
$STD dotnet build --configuration Release
$STD systemctl restart umlautadaptarr
$STD systemctl stop umlautadaptarr
temp_file=$(mktemp)
trap 'rm -f "$temp_file"' EXIT
RELEASE=$(curl -s https://api.github.com/repos/PCJones/Umlautadaptarr/releases/latest | grep "tag_name" | awk '{print substr($2, 2, length($2)-3)}')
curl -fsSL "https://github.com/PCJones/Umlautadaptarr/releases/download/${RELEASE}/linux-x64.zip" -o $temp_file
$STD unzip -u $temp_file '*/**' -d /opt/UmlautAdaptarr
$STD systemctl start umlautadaptarr
msg_ok "$APP has been updated."
exit
}