Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 19 Dec 2013 00:02:33 +0100
From:      Polytropon <freebsd@edvax.de>
To:        Graham Allan <allan@physics.umn.edu>
Cc:        freebsd-questions@freebsd.org
Subject:   Re: System Wide Bash Login Script
Message-ID:  <20131219000233.95a6e1dd.freebsd@edvax.de>
In-Reply-To: <52B1DFAB.8030300@physics.umn.edu>
References:  <BLU0-SMTP311BA69BBE6C3820F674C80B3DB0@phx.gbl> <A2F77DDA-BD32-4CBF-BA56-9DF2BF43DEE8@gmail.com> <BLU0-SMTP372E34C3B74A12DF26B7EC7B3DA0@phx.gbl> <52B1DFAB.8030300@physics.umn.edu>

next in thread | previous in thread | raw e-mail | index | archive | help
On Wed, 18 Dec 2013 11:47:23 -0600, Graham Allan wrote:
> There's a compile-time option in config-top.h ("#define SYS_BASHRC 
> ..."), which nobody seems to use.
> 
> [...] I still don't understand why 
> bash people don't see the value in this feature - having to insert that 
> snippet into everybody's personal bashrc is just stupid IMO...

It sounds wrong, especially when you consult the documentation,
"man bash", down at the "FILES" section:

/etc/profile
       The systemwide initialization file, executed for login shells

The local file ~/.bashrc, used for interactive shells (that
don't have to be login shells) doesn't seem to have a global
equivalent.

When the shell is a login shell, this should be sufficient.
A similar "precedence mechanism" has been a useful thing
for the C shell for decades: /etc/csh.cshrc, /etc/csh.login
and /etc/csh.logout are being used system-wide, which means
that its settings can benefit everyone who has an _empty_
local configuration file; only changes need to be applied
locally, if intended, so system settings could be easily
"inherited" without requiring changes to users' dotfiles,
it was just required to make sure the skel/ subtree did
privde them with empty files (that they could change them-
selves if they wanted).




-- 
Polytropon
Magdeburg, Germany
Happy FreeBSD user since 4.0
Andra moi ennepe, Mousa, ...



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20131219000233.95a6e1dd.freebsd>