This is the mail archive of the cygwin mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

RE: How do I make scripts my PC executable


On 31 August 2007 13:10, Eric Blake wrote:

> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
> 
> According to Andrew DeFaria on 8/30/2007 11:58 PM:
>> I'm always amazed how little people know about their own startup
>> environments and the reluctance to learn more about them thus improving
>> their environment and productivity. The -l option to bash *should*
>> source /etc/profile and your ~/.bash_profile. Additionally it should
>> source your .bashrc - if any of these are present.
> 
> Actually, please reread 'man bash'.  In a login shell, bash only directly
> sources /etc/profile, then the first of ~/.bash_profile, ~/.bash_login, or
> ~/.profile that exists.  Therefore, if you want ~/.bashrc sourced in login
> shells, YOU must ensure that one of the other files sources it.

  Well yeh, but in cygwin....


/artimi/software/firmware $ cat /etc/skel/.bash_profile
# base-files version 3.7-1

# To pick up the latest recommended .bash_profile content,
# look in /etc/defaults/etc/skel/.bash_profile

# Modifying /etc/skel/.bash_profile directly will prevent
# setup from updating it.

# The copy in your home directory (~/.bash_profile) is yours, please
# feel free to customise it to create a shell
# environment to your liking.  If you feel a change
# would be benifitial to all, please feel free to send
# a patch to the cygwin mailing list.

# ~/.bash_profile: executed by bash for login shells.

# source the system wide bashrc if it exists
if [ -e /etc/bash.bashrc ] ; then
  source /etc/bash.bashrc
fi

# source the users bashrc if it exists
if [ -e "${HOME}/.bashrc" ] ; then
  source "${HOME}/.bashrc"
fi

... so it /should/ be the same thing anyway.

    cheers,
      DaveK
-- 
Can't think of a witty .sigline today....


--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Problem reports:       http://cygwin.com/problems.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]