Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 8 Mar 2003 17:12:24 +0000
From:      Matthew Seaman <m.seaman@infracaninophile.co.uk>
To:        freebsd-questions@FreeBSD.ORG
Subject:   Re: bash not automatically interactive
Message-ID:  <20030308171224.GA75767@happy-idiot-talk.infracaninophi>
In-Reply-To: <3e6a1cb4$0$49109$e4fe514c@news.xs4all.nl>
References:  <3e6a1cb4$0$49109$e4fe514c@news.xs4all.nl>

next in thread | previous in thread | raw e-mail | index | archive | help
On Sat, Mar 08, 2003 at 05:40:20PM +0100, Bas Essers wrote:

> i just installed bash2 from the ports collection and used "chsh" to make it
> my shell. and now when i log in i get bash but it doesn't run in interactive
> mode, only when i start another one with "bash -i", and that's also the only
> way to get bash to read ~/.bashrc. does anyone know what the problem is?
> should i create a different startup script or something? i don't have any
> standard .bashrc, /etc/login or .bash_login files. thanks

That's normal.  When bash(1) is started as a login shell, it reads the
first one out of ~/.bash_profile, ~/.bash_login or ~/.profile it can
find.  Otherwise, for non-login shells it reads ~/.bashrc

If you want ~/.bashrc to be read for all shells, you need to add
something like the following to ~/.bash_login:

    if [ -f ${HOME}/.bashrc ] ; then
        . ${HOME}/.bashrc
    fi

	Cheers,

	Matthew

-- 
Dr Matthew J Seaman MA, D.Phil.                       26 The Paddocks
                                                      Savill Way
PGP: http://www.infracaninophile.co.uk/pgpkey         Marlow
Tel: +44 1628 476614                                  Bucks., SL7 1TH UK

To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-questions" in the body of the message




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