public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
From: "Masterson, Dave" <dmasters@rational.com>
To: 'Earnie Boyd' <earnie_boyd@yahoo.com>,
	"Masterson, Dave" <dmasters@rational.com>,
	"'cygwin@sources.redhat.com'" <cygwin@sources.redhat.com>
Subject: RE: /etc/profile in BASH
Date: Fri, 29 Sep 2000 09:42:00 -0000	[thread overview]
Message-ID: <C322F78942E6D311AF8800D0B73C4FD8830D37@CUPEX3.rational.com> (raw)

I didn't realize that a login BASH doesn't execute ~/.bashrc.  Be that as it
may, I think it should be the decision of ~/.bash_profile (or ~/.profile)
whether to execute ~/.bashrc -- *NOT* /etc/profile.  Putting this into
/etc/profile makes it too BASH-centric.  What about the [T]CSH users?  Also,
what about ~/.bash_login files (as described in the MAN page)?

-----Original Message-----
From: Earnie Boyd [ mailto:earnie_boyd@yahoo.com ]
Sent: Friday, September 29, 2000 5:04 AM
To: Masterson, Dave; 'cygwin@sources.redhat.com'
Subject: Re: /etc/profile in BASH


--- "Masterson, Dave" <dmasters@rational.com> wrote:
> Question:
> 
> In Cygwin 1.1, why are the last two lines of the installed /etc/profile
the
> following?
> 
> 	test -f ./.profile && . ./.profile
> 	test -f ./.bashrc && . ./.bashrc
> 
> As described in the BASH MAN page, it would seem that BASH does this
already
> after reading /etc/profile.  Is this required because of the
implementation
> of Cygwin on MS-Windows?
> 

IMO, the test -f ./.profile && . ./.profile isn't needed, it will get
executed
by bash anyway.  The test -f ./.bashrc && . ./.bashrc is needed because when
bash is in login state it doesn't process ~/.bashrc.  In login state both
/etc/profile and ~/.profile are executed.  In non-login state /etc/profile
and
~/.profile aren't executed but ~/.bashrc is but IIRC only for the
interactive
state.

Cheers,

=====
Earnie Boyd
mailto:earnie_boyd@yahoo.com

---         < http://earniesystems.safeshopper.com >         ---
--- Cygwin: POSIX on Windows < http://gw32.freeyellow.com/ > ---
---   Minimalist GNU for Windows < http://www.mingw.org/ >   ---

__________________________________________________
Do You Yahoo!?
Yahoo! Photos - 35mm Quality Prints, Now Get 15 Free!
http://photos.yahoo.com/

--
Want to unsubscribe from this list?
Send a message to cygwin-unsubscribe@sourceware.cygnus.com

             reply	other threads:[~2000-09-29  9:42 UTC|newest]

Thread overview: 14+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2000-09-29  9:42 Masterson, Dave [this message]
  -- strict thread matches above, loose matches on Subject: below --
2000-09-29 12:50 Earnie Boyd
2000-09-29 12:43 Masterson, Dave
2000-09-29 12:31 Earnie Boyd
2000-09-29 12:05 Earnie Boyd
2000-09-29 11:56 Masterson, Dave
2000-09-29 11:36 Earnie Boyd
2000-09-29 11:31 Masterson, Dave
2000-09-29 11:25 Earnie Boyd
2000-09-29 11:42 ` Erik Nolte
2000-09-29  5:04 Earnie Boyd
2000-09-28 14:18 Masterson, Dave
2000-09-28 11:38 Masterson, Dave
2000-09-28 13:04 ` DJ Delorie

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=C322F78942E6D311AF8800D0B73C4FD8830D37@CUPEX3.rational.com \
    --to=dmasters@rational.com \
    --cc=cygwin@sources.redhat.com \
    --cc=earnie_boyd@yahoo.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).