From b53882a489f9037fba63c8c3eaadcfd3a59441be Mon Sep 17 00:00:00 2001 From: ljf Date: Tue, 2 Mar 2021 17:31:12 +0100 Subject: [PATCH] [fix] Remove borg if no other borg or borgserver are setup --- scripts/remove | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/scripts/remove b/scripts/remove index b57c396..27cea14 100755 --- a/scripts/remove +++ b/scripts/remove @@ -43,6 +43,11 @@ ynh_secure_remove "/etc/systemd/system/$app.timer" ynh_secure_remove "/usr/local/bin/backup-with-$app" ynh_secure_remove "/etc/yunohost/hooks.d/backup_method/05-${app}_app" +if [ "$(yunohost app list | grep "id: borg" | wc -l)" == "1" ] ; then + ynh_secure_remove "/opt/borg-env" + ynh_secure_remove "/usr/local/bin/borg" +fi + #================================================= # END OF SCRIPT #=================================================