nixos/bash: use simple prompt for dumb terminals
This commit is contained in:
parent
7b001ed68a
commit
7a9982d465
|
@ -90,6 +90,7 @@ in
|
||||||
|
|
||||||
promptInit = mkOption {
|
promptInit = mkOption {
|
||||||
default = ''
|
default = ''
|
||||||
|
if test "$TERM" != "dumb"; then
|
||||||
# Provide a nice prompt.
|
# Provide a nice prompt.
|
||||||
PROMPT_COLOR="1;31m"
|
PROMPT_COLOR="1;31m"
|
||||||
let $UID && PROMPT_COLOR="1;32m"
|
let $UID && PROMPT_COLOR="1;32m"
|
||||||
|
@ -97,6 +98,7 @@ in
|
||||||
if test "$TERM" = "xterm"; then
|
if test "$TERM" = "xterm"; then
|
||||||
PS1="\[\033]2;\h:\u:\w\007\]$PS1"
|
PS1="\[\033]2;\h:\u:\w\007\]$PS1"
|
||||||
fi
|
fi
|
||||||
|
fi
|
||||||
'';
|
'';
|
||||||
description = ''
|
description = ''
|
||||||
Shell script code used to initialise the bash prompt.
|
Shell script code used to initialise the bash prompt.
|
||||||
|
|
Loading…
Reference in New Issue
Block a user