summaryrefslogtreecommitdiffstats
path: root/debian
diff options
context:
space:
mode:
authorDaniel Baumann <daniel.baumann@progress-linux.org>2024-05-05 18:23:04 +0000
committerDaniel Baumann <daniel.baumann@progress-linux.org>2024-05-05 18:23:04 +0000
commit47d58f79ebaef2ff88a64fa76f02e36febb5bc90 (patch)
tree85810c289cee7b3e90a0838c883bba276652b014 /debian
parentIncluding bash configuration files for Progress Linux. (diff)
downloadbase-files-47d58f79ebaef2ff88a64fa76f02e36febb5bc90.tar.xz
base-files-47d58f79ebaef2ff88a64fa76f02e36febb5bc90.zip
Adding bash configuration.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'debian')
-rw-r--r--debian/local/bash/profile.d/zz-bash.sh35
1 files changed, 35 insertions, 0 deletions
diff --git a/debian/local/bash/profile.d/zz-bash.sh b/debian/local/bash/profile.d/zz-bash.sh
new file mode 100644
index 0000000..9f88421
--- /dev/null
+++ b/debian/local/bash/profile.d/zz-bash.sh
@@ -0,0 +1,35 @@
+# /etc/profile.d/zz-bash.sh
+
+export PATH="/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/local/games:/usr/games"
+
+if [ "${BASH-}" ] && [ "$BASH" != "/bin/sh" ]
+then
+ if [ "$(id -u)" -eq 0 ]
+ then
+ if [ -n "$SSH_CONNECTION" ]
+ then
+ PS1="\[\033[1;31m\]\u\[\033[0m\]@\H:\w\\$ "
+ else
+ PS1="\[\033[1;31m\]\u\[\033[0m\]:\w\\$ "
+ fi
+ else
+ if [ -n "$SSH_CONNECTION" ]
+ then
+ PS1="\[\033[1;32m\]\u\[\033[0m\]@\H:\w\\$ "
+ else
+ PS1="\[\033[1;32m\]\u\[\033[0m\]:\w\\$ "
+ fi
+ fi
+
+ HISTCONTROL="ignoredups:ignorespace"
+ HISTFILESIZE="100000"
+ HISTSIZE="100000"
+
+ shopt -s cdspell
+ shopt -s checkwinsize
+ shopt -s histappend
+ shopt -s histverify
+ shopt -s no_empty_cmd_completion
+fi
+
+alias logoff="unset HISTORY; unset HISTFILE; exit"