wip/works
This commit is contained in:
parent
60adeb9f40
commit
62ae8d73cc
1 changed files with 14 additions and 6 deletions
|
@ -7,13 +7,13 @@ shell_color() {
|
|||
local code="${1}"
|
||||
case "${SH}" in
|
||||
"bash")
|
||||
printf "\e[0"
|
||||
printf "\\e[0"
|
||||
if [ -n "${code}" ]; then
|
||||
printf "%s" ";${code}"
|
||||
fi
|
||||
;;
|
||||
*)
|
||||
printf "\033["
|
||||
printf "\\033["
|
||||
if [ -n "${code}" ]; then
|
||||
printf "%s" "${code}"
|
||||
else
|
||||
|
@ -76,11 +76,13 @@ ps1() {
|
|||
fi
|
||||
fi
|
||||
# new
|
||||
view="${view}\n"
|
||||
view="${view}
|
||||
"
|
||||
# path
|
||||
view="${view}${SH_CYAN}${path}"
|
||||
# new
|
||||
view="${view}\n"
|
||||
view="${view}
|
||||
"
|
||||
# frame
|
||||
view="${view}${SH_DEFAULT}┌ "
|
||||
# user
|
||||
|
@ -92,6 +94,12 @@ ps1() {
|
|||
view="${view}${user}"
|
||||
# host
|
||||
view="${view}${SH_DEFAULT} @ "
|
||||
view="${view}${SH_BROWN}${host}${SH_DEFAULT}"
|
||||
printf "%s" "${view}\n${PS2}"
|
||||
view="${view}${SH_BROWN}${host}"
|
||||
# new
|
||||
view="${view}
|
||||
"
|
||||
# prompt
|
||||
view="${view}${SH_DEFAULT}${PS2}"
|
||||
# print
|
||||
printf "%s" "${view}"
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue