summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2016-01-24 19:59:49 -0500
committerMike Frysinger <vapier@gentoo.org>2016-01-26 02:12:10 -0500
commite3bf9d25cca2464b602a4aaafad784bbefbf322c (patch)
tree33515f683f27305b49d62c6f5a65965e8b2bacaf /app-shells
parentapp-shells/bash: Back out the `history -a` by default as it can be a bit trou... (diff)
downloadgentoo-e3bf9d25cca2464b602a4aaafad784bbefbf322c.tar.gz
gentoo-e3bf9d25cca2464b602a4aaafad784bbefbf322c.tar.bz2
gentoo-e3bf9d25cca2464b602a4aaafad784bbefbf322c.zip
app-shells/bash: merge bashrc-r# files back to bashrc
This makes the history easier to track.
Diffstat (limited to 'app-shells')
-rw-r--r--app-shells/bash/bash-4.3_p39_pre0.ebuild2
-rw-r--r--app-shells/bash/bash-4.3_p42-r1.ebuild2
-rw-r--r--app-shells/bash/bash-4.4_beta.ebuild2
-rw-r--r--app-shells/bash/files/bashrc-r192
-rw-r--r--app-shells/bash/files/bashrc-r2108
5 files changed, 3 insertions, 203 deletions
diff --git a/app-shells/bash/bash-4.3_p39_pre0.ebuild b/app-shells/bash/bash-4.3_p39_pre0.ebuild
index 2c852eef294c..4bc8ea9bce8a 100644
--- a/app-shells/bash/bash-4.3_p39_pre0.ebuild
+++ b/app-shells/bash/bash-4.3_p39_pre0.ebuild
@@ -118,7 +118,7 @@ src_install() {
insinto /etc/bash
doins "${FILESDIR}"/bash_logout
- newins "${FILESDIR}"/bashrc-r2 bashrc
+ doins "${FILESDIR}"/bashrc
keepdir /etc/bash/bashrc.d
insinto /etc/skel
for f in bash{_logout,_profile,rc} ; do
diff --git a/app-shells/bash/bash-4.3_p42-r1.ebuild b/app-shells/bash/bash-4.3_p42-r1.ebuild
index 2ffc0141cc79..8e9fbc2d3113 100644
--- a/app-shells/bash/bash-4.3_p42-r1.ebuild
+++ b/app-shells/bash/bash-4.3_p42-r1.ebuild
@@ -176,7 +176,7 @@ src_install() {
insinto /etc/bash
doins "${FILESDIR}"/bash_logout
- newins "${FILESDIR}"/bashrc-r2 bashrc
+ doins "${FILESDIR}"/bashrc
keepdir /etc/bash/bashrc.d
insinto /etc/skel
for f in bash{_logout,_profile,rc} ; do
diff --git a/app-shells/bash/bash-4.4_beta.ebuild b/app-shells/bash/bash-4.4_beta.ebuild
index fb37c2012e97..402869406034 100644
--- a/app-shells/bash/bash-4.4_beta.ebuild
+++ b/app-shells/bash/bash-4.4_beta.ebuild
@@ -173,7 +173,7 @@ src_install() {
insinto /etc/bash
doins "${FILESDIR}"/bash_logout
- newins "${FILESDIR}"/bashrc-r2 bashrc
+ doins "${FILESDIR}"/bashrc
keepdir /etc/bash/bashrc.d
insinto /etc/skel
for f in bash{_logout,_profile,rc} ; do
diff --git a/app-shells/bash/files/bashrc-r1 b/app-shells/bash/files/bashrc-r1
deleted file mode 100644
index 300070974f54..000000000000
--- a/app-shells/bash/files/bashrc-r1
+++ /dev/null
@@ -1,92 +0,0 @@
-# /etc/bash/bashrc
-#
-# This file is sourced by all *interactive* bash shells on startup,
-# including some apparently interactive shells such as scp and rcp
-# that can't tolerate any output. So make sure this doesn't display
-# anything or bad things will happen !
-
-
-# Test for an interactive shell. There is no need to set anything
-# past this point for scp and rcp, and it's important to refrain from
-# outputting anything in those cases.
-if [[ $- != *i* ]] ; then
- # Shell is non-interactive. Be done now!
- return
-fi
-
-# Bash won't get SIGWINCH if another process is in the foreground.
-# Enable checkwinsize so that bash will check the terminal size when
-# it regains control. #65623
-# http://cnswww.cns.cwru.edu/~chet/bash/FAQ (E11)
-shopt -s checkwinsize
-
-# Enable history appending instead of overwriting. #139609
-shopt -s histappend
-
-# Change the window title of X terminals
-case ${TERM} in
- xterm*|rxvt*|Eterm*|aterm|kterm|gnome*|interix|konsole*)
- PROMPT_COMMAND='echo -ne "\033]0;${USER}@${HOSTNAME%%.*}:${PWD/#$HOME/~}\007"'
- ;;
- screen*)
- PROMPT_COMMAND='echo -ne "\033_${USER}@${HOSTNAME%%.*}:${PWD/#$HOME/~}\033\\"'
- ;;
-esac
-
-use_color=false
-#BSD#@# BSD doesn't typically come with dircolors so we need
-#BSD#@# to hardcode some terminals in here.
-#BSD#@case ${TERM} in
-#BSD#@ xterm*|rxvt*|Eterm|aterm|kterm|gnome*|screen|cons25) use_color=true;;
-#BSD#@esac
-
-# Set colorful PS1 only on colorful terminals.
-# dircolors --print-database uses its own built-in database
-# instead of using /etc/DIR_COLORS. Try to use the external file
-# first to take advantage of user additions. Use internal bash
-# globbing instead of external grep binary.
-safe_term=${TERM//[^[:alnum:]]/?} # sanitize TERM
-match_lhs=""
-[[ -f ~/.dir_colors ]] && match_lhs="${match_lhs}$(<~/.dir_colors)"
-[[ -f /etc/DIR_COLORS ]] && match_lhs="${match_lhs}$(</etc/DIR_COLORS)"
-[[ -z ${match_lhs} ]] \
- && type -P dircolors >/dev/null \
- && match_lhs=$(dircolors --print-database)
-[[ $'\n'${match_lhs} == *$'\n'"TERM "${safe_term}* ]] && use_color=true
-
-if ${use_color} ; then
- # Enable colors for ls, etc. Prefer ~/.dir_colors #64489
- if type -P dircolors >/dev/null ; then
- if [[ -f ~/.dir_colors ]] ; then
- eval $(dircolors -b ~/.dir_colors)
- elif [[ -f /etc/DIR_COLORS ]] ; then
- eval $(dircolors -b /etc/DIR_COLORS)
- fi
- fi
-
- if [[ ${EUID} == 0 ]] ; then
- PS1='\[\033[01;31m\]\h\[\033[01;34m\] \W \$\[\033[00m\] '
- else
- PS1='\[\033[01;32m\]\u@\h\[\033[01;34m\] \w \$\[\033[00m\] '
- fi
-
- #BSD#@export CLICOLOR=1
- #GNU#@alias ls='ls --color=auto'
- alias grep='grep --colour=auto'
- alias egrep='egrep --colour=auto'
- alias fgrep='fgrep --colour=auto'
-else
- if [[ ${EUID} == 0 ]] ; then
- # show root@ when we don't have colors
- PS1='\u@\h \W \$ '
- else
- PS1='\u@\h \w \$ '
- fi
-fi
-
-for sh in /etc/bash/bashrc.d/* ; do
- [[ -r ${sh} ]] && source "${sh}"
-done
-
-# Try to keep environment pollution down, EPA loves us.
-unset use_color safe_term match_lhs sh
diff --git a/app-shells/bash/files/bashrc-r2 b/app-shells/bash/files/bashrc-r2
deleted file mode 100644
index c9bd88e85868..000000000000
--- a/app-shells/bash/files/bashrc-r2
+++ /dev/null
@@ -1,108 +0,0 @@
-# /etc/bash/bashrc
-#
-# This file is sourced by all *interactive* bash shells on startup,
-# including some apparently interactive shells such as scp and rcp
-# that can't tolerate any output. So make sure this doesn't display
-# anything or bad things will happen !
-
-
-# Test for an interactive shell. There is no need to set anything
-# past this point for scp and rcp, and it's important to refrain from
-# outputting anything in those cases.
-if [[ $- != *i* ]] ; then
- # Shell is non-interactive. Be done now!
- return
-fi
-
-# Bash won't get SIGWINCH if another process is in the foreground.
-# Enable checkwinsize so that bash will check the terminal size when
-# it regains control. #65623
-# http://cnswww.cns.cwru.edu/~chet/bash/FAQ (E11)
-shopt -s checkwinsize
-
-# Disable completion when the input buffer is empty. i.e. Hitting tab
-# and waiting a long time for bash to expand all of $PATH.
-shopt -s no_empty_cmd_completion
-
-# Enable history appending instead of overwriting when exiting. #139609
-shopt -s histappend
-
-# Save each command to the history file as it's executed. #517342
-# This does mean sessions get interleaved when reading later on, but this
-# way the history is always up to date. History is not synced across live
-# sessions though; that is what `history -n` does.
-# Disabled by default due to concerns related to system recovery when $HOME
-# is under duress, or lives somewhere flaky (like NFS). Constantly syncing
-# the history will halt the shell prompt until it's finished.
-#PROMPT_COMMAND='history -a'
-
-# Change the window title of X terminals
-case ${TERM} in
- xterm*|rxvt*|Eterm*|aterm|kterm|gnome*|interix|konsole*)
- PS1='\[\033]0;\u@\h:\w\007\]'
- ;;
- screen*)
- PS1='\[\033k\u@\h:\w\033\\\]'
- ;;
- *)
- unset PS1
- ;;
-esac
-
-use_color=false
-#BSD#@# BSD doesn't typically come with dircolors so we need
-#BSD#@# to hardcode some terminals in here.
-#BSD#@case ${TERM} in
-#BSD#@ xterm*|rxvt*|Eterm|aterm|kterm|gnome*|screen|cons25) use_color=true;;
-#BSD#@esac
-
-# Set colorful PS1 only on colorful terminals.
-# dircolors --print-database uses its own built-in database
-# instead of using /etc/DIR_COLORS. Try to use the external file
-# first to take advantage of user additions. Use internal bash
-# globbing instead of external grep binary.
-safe_term=${TERM//[^[:alnum:]]/?} # sanitize TERM
-match_lhs=""
-[[ -f ~/.dir_colors ]] && match_lhs="${match_lhs}$(<~/.dir_colors)"
-[[ -f /etc/DIR_COLORS ]] && match_lhs="${match_lhs}$(</etc/DIR_COLORS)"
-[[ -z ${match_lhs} ]] \
- && type -P dircolors >/dev/null \
- && match_lhs=$(dircolors --print-database)
-[[ $'\n'${match_lhs} == *$'\n'"TERM "${safe_term}* ]] && use_color=true
-
-if ${use_color} ; then
- # Enable colors for ls, etc. Prefer ~/.dir_colors #64489
- if type -P dircolors >/dev/null ; then
- if [[ -f ~/.dir_colors ]] ; then
- eval $(dircolors -b ~/.dir_colors)
- elif [[ -f /etc/DIR_COLORS ]] ; then
- eval $(dircolors -b /etc/DIR_COLORS)
- fi
- fi
-
- if [[ ${EUID} == 0 ]] ; then
- PS1+='\[\033[01;31m\]\h\[\033[01;34m\] \W \$\[\033[00m\] '
- else
- PS1+='\[\033[01;32m\]\u@\h\[\033[01;34m\] \w \$\[\033[00m\] '
- fi
-
- #BSD#@export CLICOLOR=1
- #GNU#@alias ls='ls --color=auto'
- alias grep='grep --colour=auto'
- alias egrep='egrep --colour=auto'
- alias fgrep='fgrep --colour=auto'
-else
- if [[ ${EUID} == 0 ]] ; then
- # show root@ when we don't have colors
- PS1+='\u@\h \W \$ '
- else
- PS1+='\u@\h \w \$ '
- fi
-fi
-
-for sh in /etc/bash/bashrc.d/* ; do
- [[ -r ${sh} ]] && source "${sh}"
-done
-
-# Try to keep environment pollution down, EPA loves us.
-unset use_color safe_term match_lhs sh