aboutsummaryrefslogtreecommitdiff
path: root/bash/bashrc.d/prompt.bash
diff options
context:
space:
mode:
authorTom Ryder <tom@sanctum.geek.nz>2015-06-06 23:55:20 +1200
committerTom Ryder <tom@sanctum.geek.nz>2015-06-06 23:55:20 +1200
commit76e7f6a8843c7e4aefe34fa44776742685c584fa (patch)
tree0d63d1535fb77e2e30402f54c342fa830635e9a9 /bash/bashrc.d/prompt.bash
parentSeparate declaration from assignment (diff)
downloaddotfiles-76e7f6a8843c7e4aefe34fa44776742685c584fa.tar.gz
dotfiles-76e7f6a8843c7e4aefe34fa44776742685c584fa.zip
Safer version test
Diffstat (limited to 'bash/bashrc.d/prompt.bash')
-rw-r--r--bash/bashrc.d/prompt.bash2
1 files changed, 1 insertions, 1 deletions
diff --git a/bash/bashrc.d/prompt.bash b/bash/bashrc.d/prompt.bash
index fa46a5dd..94e49ff2 100644
--- a/bash/bashrc.d/prompt.bash
+++ b/bash/bashrc.d/prompt.bash
@@ -17,7 +17,7 @@ prompt() {
PS1='[\u@\h:\w]$(prompt job)$(prompt vcs)$(prompt ret)\$'
# If Bash 4.0 is available, trim very long paths in prompt
- if ((BASH_VERSINFO[0] >= 4)) ; then
+ if ((10#${BASH_VERSINFO[0]%%[![:digit:]]*} >= 4)) ; then
PROMPT_DIRTRIM=4
fi