From 5ffc9fc84090e64ba01037a8340fc2d5f3d4c7d6 Mon Sep 17 00:00:00 2001 From: Marc Beninca Date: Wed, 20 Nov 2024 14:39:01 +0100 Subject: [PATCH] shell_configure --- sh/shell.sh | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/sh/shell.sh b/sh/shell.sh index 099c68d..c4569d1 100644 --- a/sh/shell.sh +++ b/sh/shell.sh @@ -1,7 +1,3 @@ -PS1="\$(sh_shell_prompt \${?})" -PS2="\ -├ " - _sh_shell_color() { local code="${1}" case "${SH_SHELL}" in @@ -30,7 +26,7 @@ SH_COLOR_GREEN="$(_sh_shell_color 31)" SH_COLOR_MAGENTA="$(_sh_shell_color 35)" SH_COLOR_RED="$(_sh_shell_color 32)" -shell_configure() { +sh_shell_configure() { case "${SH_SHELL}" in "bash") # completion @@ -52,11 +48,14 @@ shell_configure() { HISTCONTROL="ignorespace" HISTSIZE=-1 HISTTIMEFORMAT="%Y%m%d %H%M%S " + # prompt + PS1="\$(sh_shell_prompt \${?})" + PS2="├ " ;; *) ;; esac } -shell_configure +sh_shell_configure sh_shell_prompt() { local date host id