From f0ca99720432f971d312285596b3773d4521f296 Mon Sep 17 00:00:00 2001 From: lemmi Date: Tue, 4 Aug 2015 14:13:25 +0200 Subject: [PATCH] bash: source system bashrc on login --- srcpkgs/bash/files/bash.sh | 7 +++++++ srcpkgs/bash/template | 3 ++- 2 files changed, 9 insertions(+), 1 deletion(-) create mode 100644 srcpkgs/bash/files/bash.sh diff --git a/srcpkgs/bash/files/bash.sh b/srcpkgs/bash/files/bash.sh new file mode 100644 index 0000000000..f3295fd147 --- /dev/null +++ b/srcpkgs/bash/files/bash.sh @@ -0,0 +1,7 @@ +# Check for interactive bash +[ -z "$BASH_VERSION" -o -z "$PS1" ] && return + +# Bash login shells only run /etc/profile +# Bash non-login shells run only /etc/bash/bashrc +# We want to source /etc/bash/bashrc in any case +[ -f /etc/bash/bashrc ] && . /etc/bash/bashrc diff --git a/srcpkgs/bash/template b/srcpkgs/bash/template index 3f8be20087..ced3013169 100644 --- a/srcpkgs/bash/template +++ b/srcpkgs/bash/template @@ -3,7 +3,7 @@ pkgname=bash _bash_distver=4.3 _bash_patchlevel=039 version=${_bash_distver}.${_bash_patchlevel} -revision=5 +revision=6 wrksrc=${pkgname}-${_bash_distver} build_pie=yes build_style=gnu-configure @@ -45,4 +45,5 @@ post_install() { ln -s bash ${DESTDIR}/usr/bin/rbash vmkdir /etc/bash vinstall ${FILESDIR}/bashrc 644 etc/bash + vinstall ${FILESDIR}/bash.sh 644 etc/profile.d }