From 979ee3ed3e24adf9048b887718ae586f2a1ee563 Mon Sep 17 00:00:00 2001 From: Kyler Clay Date: Wed, 2 Oct 2024 03:47:30 -0400 Subject: [PATCH] Commit for generation 160 --- glasshouse-desktop/modules/zshell.nix | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/glasshouse-desktop/modules/zshell.nix b/glasshouse-desktop/modules/zshell.nix index e9407d3..21cf1c9 100644 --- a/glasshouse-desktop/modules/zshell.nix +++ b/glasshouse-desktop/modules/zshell.nix @@ -186,9 +186,9 @@ safe_rm() { fi # Perform the removal if no checks or confirmation is "y" - played_sound=0 if [ "$check" = false ] || [ "$confirm" = "y" ]; then - [ $played_sound -eq 0 ] && sounds_enabled && (aplay ~/sound/sys/rm.wav > /dev/null 2>&1 &) && played_sound=1 + sounds_enabled && (aplay ~/sound/sys/rm.wav > /dev/null 2>&1 &) && played_sound=1 + export SOUNDS_ENABLED=0 /run/current-system/sw/bin/rm -rfv "$dir" else echo "Operation cancelled for '$dir'." @@ -197,6 +197,7 @@ safe_rm() { echo "'$dir' does not exist or is not accessible." fi done + export SOUNDS_ENABLED=1 }