diff options
| author | Silvio Rhatto <rhatto@riseup.net> | 2015-03-09 12:24:33 -0300 | 
|---|---|---|
| committer | Silvio Rhatto <rhatto@riseup.net> | 2015-03-09 12:24:33 -0300 | 
| commit | 49b61b18ba28a40fc4139acf717deea952061818 (patch) | |
| tree | 258867a7844be9353da56e4d6b70b50f9065d2ae /files | |
| parent | 150ad07e99e8450ef22b707ef610559493567a9f (diff) | |
| download | puppet-nodo-49b61b18ba28a40fc4139acf717deea952061818.tar.gz puppet-nodo-49b61b18ba28a40fc4139acf717deea952061818.tar.bz2 | |
Keep managing /etc/bash.bashrc
Diffstat (limited to 'files')
| -rw-r--r-- | files/etc/bash.bashrc | 22 | ||||
| -rw-r--r-- | files/etc/profile | 5 | ||||
| -rw-r--r-- | files/etc/profile.d/prompt.sh (renamed from files/bin/prompt.sh) | 0 | 
3 files changed, 16 insertions, 11 deletions
| diff --git a/files/etc/bash.bashrc b/files/etc/bash.bashrc index 5e594b7..8faf820 100644 --- a/files/etc/bash.bashrc +++ b/files/etc/bash.bashrc @@ -11,7 +11,7 @@  shopt -s checkwinsize  # set variable identifying the chroot you work in (used in the prompt below) -if [ -z "$debian_chroot" ] && [ -r /etc/debian_chroot ]; then +if [ -z "${debian_chroot:-}" ] && [ -r /etc/debian_chroot ]; then      debian_chroot=$(cat /etc/debian_chroot)  fi @@ -19,7 +19,7 @@ fi  #PS1='${debian_chroot:+($debian_chroot)}\u@\h:\w\$ '  # set a fancy prompt -. /usr/local/bin/prompt.sh +. /etc/profile.d/prompt.sh  # Commented out, don't overwrite xterm -T "title" -n "icontitle" by default.  # If this is an xterm set the title to user@host:dir @@ -32,18 +32,26 @@ fi  #esac  # enable bash completion in interactive shells -if [ -f /etc/bash_completion ]; then -    . /etc/bash_completion -fi +#if ! shopt -oq posix; then +#  if [ -f /usr/share/bash-completion/bash_completion ]; then +#    . /usr/share/bash-completion/bash_completion +#  elif [ -f /etc/bash_completion ]; then +#    . /etc/bash_completion +#  fi +#fi  # if the command-not-found package is installed, use it -if [ -x /usr/lib/command-not-found ]; then +if [ -x /usr/lib/command-not-found -o -x /usr/share/command-not-found/command-not-found ]; then  	function command_not_found_handle {  	        # check because c-n-f could've been removed in the meantime                  if [ -x /usr/lib/command-not-found ]; then -		   /usr/bin/python /usr/lib/command-not-found -- $1 +		   /usr/lib/command-not-found -- "$1" +                   return $? +                elif [ -x /usr/share/command-not-found/command-not-found ]; then +		   /usr/share/command-not-found/command-not-found -- "$1"                     return $?  		else +		   printf "%s: command not found\n" "$1" >&2  		   return 127  		fi  	} diff --git a/files/etc/profile b/files/etc/profile index 5a89ea5..51d0430 100644 --- a/files/etc/profile +++ b/files/etc/profile @@ -9,7 +9,7 @@ fi  export PATH  if [ "$PS1" ]; then -  if [ "$BASH" ]; then +  if [ "$BASH" ] && [ "$BASH" != "/bin/sh" ]; then      # The file bash.bashrc already sets the default PS1.      # PS1='\h:\w\$ '      if [ -f /etc/bash.bashrc ]; then @@ -24,9 +24,6 @@ if [ "$PS1" ]; then    fi  fi -# The default umask is now handled by pam_umask. -# See pam_umask(8) and /etc/login.defs. -  if [ -d /etc/profile.d ]; then    for i in /etc/profile.d/*.sh; do      if [ -r $i ]; then diff --git a/files/bin/prompt.sh b/files/etc/profile.d/prompt.sh index 8247b1a..8247b1a 100644 --- a/files/bin/prompt.sh +++ b/files/etc/profile.d/prompt.sh | 
