Commit for generation 160

This commit is contained in:
2024-10-02 03:47:30 -04:00
parent 0d3f494113
commit 979ee3ed3e

View File

@@ -186,9 +186,9 @@ safe_rm() {
fi fi
# Perform the removal if no checks or confirmation is "y" # Perform the removal if no checks or confirmation is "y"
played_sound=0
if [ "$check" = false ] || [ "$confirm" = "y" ]; then 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" /run/current-system/sw/bin/rm -rfv "$dir"
else else
echo "Operation cancelled for '$dir'." echo "Operation cancelled for '$dir'."
@@ -197,6 +197,7 @@ safe_rm() {
echo "'$dir' does not exist or is not accessible." echo "'$dir' does not exist or is not accessible."
fi fi
done done
export SOUNDS_ENABLED=1
} }