Rename the function to be more consistent and add a sane default check.

This commit is contained in:
2025-11-10 17:01:58 -07:00
parent dff1560f6f
commit 50d3104f9f

View File

@@ -1,7 +1,7 @@
#!/usr/bin/env bash
# 2025-11-10 Hyperling
function storage {
function storage-display {
location="$1"
style="$2"
@@ -17,6 +17,7 @@ function storage {
df -h "$location" | tail -n 1 | awk '{print $5" Free, "$3"/"$2" Used"}'
fi
}
alias storage='echo -n "Root: " && storage-display "/" && echo -n "Home: " && storage-display "/home"'
export dwm_storage_style="usage"