From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from lists.gentoo.org ([140.105.134.102] helo=robin.gentoo.org) by finch.gentoo.org with esmtp (Exim 4.60) (envelope-from ) id 1IXzvN-0005Eb-V6 for garchives@archives.gentoo.org; Wed, 19 Sep 2007 13:49:06 +0000 Received: from robin.gentoo.org (localhost [127.0.0.1]) by robin.gentoo.org (8.14.0/8.14.0) with SMTP id l8JDd8su027346; Wed, 19 Sep 2007 13:39:08 GMT Received: from dcnode-01.unlimitedmail.net (static-adsl-b-16-58.ipcom.comunitel.net [212.145.239.58] (may be forged)) by robin.gentoo.org (8.14.0/8.14.0) with ESMTP id l8JDXFLt020017 for ; Wed, 19 Sep 2007 13:33:16 GMT Received: from ppp.zz ([137.204.208.98]) (authenticated bits=0) by dcnode-01.unlimitedmail.net (8.14.0/8.14.0) with ESMTP id l8JDWsg9015783 for ; Wed, 19 Sep 2007 15:32:55 +0200 From: Etaoin Shrdlu To: gentoo-user@lists.gentoo.org Subject: Re: [gentoo-user] man bash document doesn't match real life bash. Date: Wed, 19 Sep 2007 15:43:20 +0200 User-Agent: KMail/1.9.7 References: <46F13A34.4080201@ergolight-sw.com> <20070919142308.259ef440@zaphod.digimed.co.uk> In-Reply-To: <20070919142308.259ef440@zaphod.digimed.co.uk> Precedence: bulk List-Post: List-Help: List-Unsubscribe: List-Subscribe: List-Id: Gentoo Linux mail X-BeenThere: gentoo-user@gentoo.org Reply-to: gentoo-user@lists.gentoo.org MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Content-Disposition: inline Message-Id: <200709191543.20612.shrdlu@unlimitedmail.org> X-UnlimitedMail-MailScanner: Found to be clean X-UnlimitedMail-MailScanner-From: shrdlu@unlimitedmail.org X-Spam-Status: No X-Archives-Salt: 0f42bbd7-10ae-4a27-9438-01edadb292d0 X-Archives-Hash: 11d68e33061cf797793eb33a752a0bfc On Wednesday 19 September 2007, Neil Bothwick wrote: > On Wed, 19 Sep 2007 17:03:16 +0200, David Harel wrote: > > Where real life uses /etc/bash/bashrc > > This part is taken from strace dump: strace bash -i > > open("/etc/bash/bashrc", O_RDONLY|O_LARGEFILE) = 3 > > It reads both, this is from /etc/profile > > if [ -n "${BASH_VERSION}" ] ; then > # Newer bash ebuilds include /etc/bash/bashrc which will setup PS1 > # including color. We leave out color here because not all > # terminals support it. > if [ -f /etc/bash/bashrc ] ; then > # Bash login shells run only /etc/profile > # Bash non-login shells run only /etc/bash/bashrc > # Since we want to run /etc/bash/bashrc regardless, we source > it # from here. It is unfortunate that there is no way to do # this > *after* the user's .bash_profile runs (without putting # it in the > user's dot-files), but it shouldn't make any # difference. > . /etc/bash/bashrc It reads both, but the "Bash non-login shells run only /etc/bash/bashrc" behavior is not documented in man bash. -- gentoo-user@gentoo.org mailing list