diff --git a/zsh/zshrc b/zsh/zshrc index 8a2160c..7b58ea2 100644 --- a/zsh/zshrc +++ b/zsh/zshrc @@ -71,7 +71,7 @@ function dotfiles-update() { function context-color() { hexcount=$(($(infocmp -1 | sed -n -e 's/^\t*colors#\([0-9]x\?[0-9]*\),.*/\1/p')-1)) - hash=$(hostname | md5sum | head -c 6 | tr '[:lower:]' '[:upper:]') + hash=$(printf "%d\n" "0x$(hostname | md5sum | head -c 6 | tr '[:lower:]' '[:upper:]')") excludes="0,7,15" id=$(( $hash % $hexcount )) for excid in $(echo "$excludes" | tr "," '\n'); do