aboutsummaryrefslogtreecommitdiffstats
path: root/.zshrc-linux
diff options
context:
space:
mode:
Diffstat (limited to '.zshrc-linux')
-rw-r--r--.zshrc-linux6
1 files changed, 3 insertions, 3 deletions
diff --git a/.zshrc-linux b/.zshrc-linux
index 46d325f..03ab373 100644
--- a/.zshrc-linux
+++ b/.zshrc-linux
@@ -23,9 +23,9 @@ export PAGER="less -R"
# bits to human readable value
b2h() {
- suffixes=( 'B' 'K' 'M' 'G' 'T' 'P' 'E' 'Z' 'Y' )
- sindex=1
- val=$1
+ local suffixes=( 'B' 'K' 'M' 'G' 'T' 'P' 'E' 'Z' 'Y' )
+ local sindex=1
+ local val=$1
[[ -z $(echo $1 | grep "^[0-9]*$") ]] && read val
while [[ $(echo $val / 1024 | bc) -ne 0 ]]; do