aboutsummaryrefslogtreecommitdiffstats
path: root/.zshrc-freebsd
diff options
context:
space:
mode:
Diffstat (limited to '.zshrc-freebsd')
-rw-r--r--.zshrc-freebsd6
1 files changed, 3 insertions, 3 deletions
diff --git a/.zshrc-freebsd b/.zshrc-freebsd
index 0525972..04cc950 100644
--- a/.zshrc-freebsd
+++ b/.zshrc-freebsd
@@ -16,9 +16,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