From 8e3be885985299814d2cc499091a6a31908365a7 Mon Sep 17 00:00:00 2001 From: pvincent Date: Sat, 22 Aug 2026 20:06:55 +0400 Subject: [PATCH] real latest install --- lib/self-upgrade.bash | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/lib/self-upgrade.bash b/lib/self-upgrade.bash index cfd6c1c..8169ecd 100644 --- a/lib/self-upgrade.bash +++ b/lib/self-upgrade.bash @@ -53,10 +53,12 @@ function perform_upgrade { sudo mv "$MIAOU_BASH_DIR" "$backup" curl -s --output /tmp/miaou-bash-install.sh "$INSTALL_URL" + # if "$backup"/install.sh upgraded; then # shellcheck disable=SC1091 if source /tmp/miaou-bash-install.sh upgrade; then - # if "$backup"/install.sh upgraded; then - sudo mv "$backup"/hooks.d/* "$MIAOU_BASH_DIR/hooks.d/" + if [[ $(find "$backup"/hooks.d -maxdepth 1 -type f | wc -l) -gt 0 ]]; then + sudo mv "$backup"/hooks.d/* "$MIAOU_BASH_DIR"/hooks.d/ + fi sudo rm -rf "$backup" cat <