From eae66f99675b20d64c8949a8f6a1ae083b870c91 Mon Sep 17 00:00:00 2001 From: Hyperling Date: Mon, 10 Nov 2025 14:57:00 -0700 Subject: [PATCH] Add back in direct volume assignment, may have been cut and not copied back in. Re-test to ensure all is working well. --- files/dwm/volume.function | 10 +++++++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --git a/files/dwm/volume.function b/files/dwm/volume.function index 39664c5..325ba47 100755 --- a/files/dwm/volume.function +++ b/files/dwm/volume.function @@ -49,7 +49,7 @@ function volume { fi dir="" - typeset -i amt + amt="" # Check if format is written text. if [[ "$1" == "full" || "$1" == "max" ]]; then @@ -89,11 +89,15 @@ function volume { fi if [[ -n "$dir" && -z "$amt" ]]; then amt="$1" + amt=${amt//-/} + amt=${amt//+/} fi fi - amt=${amt//-/} - amt=${amt//+/} + # Check if format is direct volume. + if [[ -z "$dir" && -z "$amt" && -n "$1" && -z "$2" ]]; then + amt="$1" + fi if [[ -n "$dir" && -n "$amt" ]]; then echo "> Changing volume by '$dir$amt%'."