From 20c27aa959a02b762b8ff98bc71150b4a2e300fe Mon Sep 17 00:00:00 2001 From: Michel Roegl-Brunner Date: Thu, 15 May 2025 15:42:38 +0200 Subject: [PATCH] test remove script --- misc/build.func | 9 +++++++++ misc/tools.func | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/misc/build.func b/misc/build.func index 9b1fdcd..65b53ef 100644 --- a/misc/build.func +++ b/misc/build.func @@ -1428,6 +1428,15 @@ EOF systemctl start ping-instances.service fi + read -p "Remove this script? " prompt + if [[ "${prompt,,}" =~ ^(y|yes)$ ]]; then + pct stop "$CTID" + pct remove "$CTID" + msg_ok "Removed this script" + else + msg_warn "Did not remove this script" + fi + post_update_to_api "done" "none" } diff --git a/misc/tools.func b/misc/tools.func index 65c2cbe..46ff442 100644 --- a/misc/tools.func +++ b/misc/tools.func @@ -443,7 +443,7 @@ install_composer() { # Download and install latest composer curl -fsSL https://getcomposer.org/installer -o /tmp/composer-setup.php - script -q -c "php /tmp/composer-setup.php --install-dir=/usr/local/bin --filename=composer" >/dev/null + php /tmp/composer-setup.php --install-dir=/usr/local/bin --filename=composer if [[ $? -ne 0 ]]; then msg_error "Failed to install Composer"