public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
* RE: Start-up files for bash?
@ 1997-03-14 21:00 Boatwright, Charles
  0 siblings, 0 replies; 6+ messages in thread
From: Boatwright, Charles @ 1997-03-14 21:00 UTC (permalink / raw)
  To: 'gnu-win32@cygnus.com', 'sissonlh@esper.com'

Len,

Depending on your configuration .bashrc is read from the HOME,  
failing a HOME environment var (and proper directory) .bashrc is read
from
root.  I have not tested this with strange mounts.  

bash in NT is "sorta" unix.  My best teacher for this has been comparing
bash activities on FreeBSD to my NT station.

hope this helps.

-c


>----------
>From: 	sissonlh@esper.com[SMTP:sissonlh@esper.com]
>Sent: 	Friday, March 14, 1997 6:25 AM
>To: 	gnu-win32@cygnus.com
>Subject: 	Start-up files for bash?
>
>I have just installed the Cygnus Win32 utility binaries including Bash under
>Win 95.  A few years ago I had & helped do admin on a Sun Sparc system and
>used mostly csh.  As I recall, we had both system startup and individual
>login startup (something like .cshrc, .profile?) files as well as such files
>as some in an /etc directory (hosts & others).  I assume such startup files
>are implemented for the Win 32 port of Bash, but I haven't run across the
>documentation on how to do that yet.  Can anyone tell me where I can find
>that info?
>
>Len Sisson
>Knoxville, TN
>
>-
>For help on using this list, send a message to
>"gnu-win32-request@cygnus.com" with one line of text: "help".
>
-
For help on using this list, send a message to
"gnu-win32-request@cygnus.com" with one line of text: "help".

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Start-up files for bash?
@ 1997-03-15  0:54 Weiqi Gao
  0 siblings, 0 replies; 6+ messages in thread
From: Weiqi Gao @ 1997-03-15  0:54 UTC (permalink / raw)
  To: gnu-win32

Leonard Sisson <sissonlh@esper.com> wrote:

>I have just installed the Cygnus Win32 utility binaries including Bash
under
>Win 95.  A few years ago I had & helped do admin on a Sun Sparc system and
>used mostly csh.  As I recall, we had both system startup and individual
>login startup (something like .cshrc, .profile?) files as well as such
files
>as some in an /etc directory (hosts & others).  I assume such startup
files
>are implemented for the Win 32 port of Bash, but I haven't run across the
>documentation on how to do that yet.  Can anyone tell me where I can find
>that info?

I think the Win32 bash uses the standard start-up files.  The ones in /etc
first, and the ones in ~.  Where "/" is determined by the mount command,
and "~" is determined by the HOME environment variable.

--
Weiqi Gao
weiqigao@crl.com
-
For help on using this list, send a message to
"gnu-win32-request@cygnus.com" with one line of text: "help".

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Start-up files for bash?
  1997-03-14  6:27 Leonard Sisson
  1997-03-14 13:38 ` Ed Huott
@ 1997-03-14 21:00 ` Horia F Pop
  1997-03-14 21:00 ` Sheik
  2 siblings, 0 replies; 6+ messages in thread
From: Horia F Pop @ 1997-03-14 21:00 UTC (permalink / raw)
  To: Leonard Sisson; +Cc: gnu-win32

Leonard Sisson wrote:
> 
> I have just installed the Cygnus Win32 utility binaries including Bash under
> Win 95.  A few years ago I had & helped do admin on a Sun Sparc system and
> used mostly csh.  As I recall, we had both system startup and individual
> login startup (something like .cshrc, .profile?) files as well as such files
> as some in an /etc directory (hosts & others).  I assume such startup files
> are implemented for the Win 32 port of Bash, but I haven't run across the
> documentation on how to do that yet.  Can anyone tell me where I can find
> that info?

Well, you will have to do the following:

(1) Prepare a batch file, let's say go-bash.bat with the following
contents:

set PATH=c:\cygnus\H-i386-cygwin32\bin;%PATH%
set HOME=c:\myfiles
bash

Of course you will modify the paths according to your situation.

(2) In your 'home' directory as given by the %HOME% variable you will
need the following files:

.bashrc		 will be sourced at the start of non-login shells
.bash_profile    will be sourced at login 
.bash_logout     will be sourced at logout

Be careful as the .bash* files need to be Unix-type ASCII files, not
Dos-type.

(3) For more info see the file c:\cygnus\man\man1\bash.1

I hope this helps.

Horia Pop

-------------------------------------------------------------------
Dr. Horia F. Pop, Lecturer Professor	Phone:	+40-64-194.315/154
Department of Computer Science		Fax:	+40-64-191.906
"Babes-Bolyai" University, Cluj, RO	Home:	+40-64-197.254
http://www.cs.ubbcluj.ro/~hfpop		E-mail:	hfpop@cs.ubbcluj.ro
http://www.geocities.com/CapeCanaveral/9645	hfpop@iname.com
-
For help on using this list, send a message to
"gnu-win32-request@cygnus.com" with one line of text: "help".

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Start-up files for bash?
  1997-03-14  6:27 Leonard Sisson
  1997-03-14 13:38 ` Ed Huott
  1997-03-14 21:00 ` Horia F Pop
@ 1997-03-14 21:00 ` Sheik
  2 siblings, 0 replies; 6+ messages in thread
From: Sheik @ 1997-03-14 21:00 UTC (permalink / raw)
  To: Leonard Sisson; +Cc: gnu-win32

On Fri, 14 Mar 1997, Leonard Sisson wrote:

> I have just installed the Cygnus Win32 utility binaries including Bash under
> Win 95.  A few years ago I had & helped do admin on a Sun Sparc system and
> used mostly csh.  As I recall, we had both system startup and individual
> login startup (something like .cshrc, .profile?) files as well as such files
> as some in an /etc directory (hosts & others).  I assume such startup files
> are implemented for the Win 32 port of Bash, but I haven't run across the
> documentation on how to do that yet.  Can anyone tell me where I can find
> that info?

  Well, I can explain how I set up my system, I think it works pretty 
well. =) (On win95 that is)

 first off, I made a  d:\etc dir (change the d: to whatever you plan to 
use as your main filesystem.   then I made a bogus /etc/passwd file that 
looks like this.

sheik:x:500:100:sheik:/root:/bin/sh

now you have a passwd entry for yourself, and bash will look at this when 
you load it.  the important part is the  /root  bash will then look for a 
file called  /root/.bashrc  and run that if it exists.  Also, my port of 
ssh will also need this as ssh needs to make a  /root/.ssh dir.

Incidently, making the passwd file with a path to your home dir makes a 
LOT of programs "work", that I was having a tough time trying to figure 
out a way to make it work =)

also, I use the "mount" command to make things a little more nicer looking...

bash$ mount
Device           Directory           Type        Flags
d:\usr\include   /usr/include        native      no-mixed,text=binary
d:\tmp           /tmp                native      no-mixed,text=binary
d:\root          /root               native      no-mixed,text!=binary
d:\etc           /etc                native      no-mixed,text=binary
\\.\tape1:       /dev/st1            native      no-mixed,text!=binary
\\.\tape0:       /dev/st0            native      no-mixed,text!=binary
\\.\b:           /dev/fd1            native      no-mixed,text!=binary
\\.\a:           /dev/fd0            native      no-mixed,text!=binary
d:\bin           /bin                native      no-mixed,text=binary
h:               /                   native      no-mixed,text=binary

Notice the switching back and forth from text=binary and text!=binary.
its a very odd thing, things like "patch" command seems to need the 
text=binary on the file system, but other things break with that same 
thing. (my .bashrc breaks when it is text=binary)

Sheik
-
For help on using this list, send a message to
"gnu-win32-request@cygnus.com" with one line of text: "help".

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Re: Start-up files for bash?
  1997-03-14  6:27 Leonard Sisson
@ 1997-03-14 13:38 ` Ed Huott
  1997-03-14 21:00 ` Horia F Pop
  1997-03-14 21:00 ` Sheik
  2 siblings, 0 replies; 6+ messages in thread
From: Ed Huott @ 1997-03-14 13:38 UTC (permalink / raw)
  To: Leonard Sisson; +Cc: gnu-win32

In message < 199703141425.JAA02254@alpha.esper.com >, Leonard Sisson writes:
>I have just installed the Cygnus Win32 utility binaries including Bash under
>Win 95.  A few years ago I had & helped do admin on a Sun Sparc system and
>used mostly csh.  As I recall, we had both system startup and individual
>login startup (something like .cshrc, .profile?) files as well as such files
>as some in an /etc directory (hosts & others).  I assume such startup files
>are implemented for the Win 32 port of Bash, but I haven't run across the
>documentation on how to do that yet.  Can anyone tell me where I can find
>that info?
>
The bash shell is fully documented in the info/bash.info file that
should reside under the root of your cygwin32 installation.  You will
find a discussion of the startup files it uses there.

This file is most easily browsed with an info file viewer such as the
one built into emacs.  It is, however, a mostly ASCII file, so any
reasonable editor or file viewer (even your web browser) will do.

<ED>
-
For help on using this list, send a message to
"gnu-win32-request@cygnus.com" with one line of text: "help".

^ permalink raw reply	[flat|nested] 6+ messages in thread

* Start-up files for bash?
@ 1997-03-14  6:27 Leonard Sisson
  1997-03-14 13:38 ` Ed Huott
                   ` (2 more replies)
  0 siblings, 3 replies; 6+ messages in thread
From: Leonard Sisson @ 1997-03-14  6:27 UTC (permalink / raw)
  To: gnu-win32

I have just installed the Cygnus Win32 utility binaries including Bash under
Win 95.  A few years ago I had & helped do admin on a Sun Sparc system and
used mostly csh.  As I recall, we had both system startup and individual
login startup (something like .cshrc, .profile?) files as well as such files
as some in an /etc directory (hosts & others).  I assume such startup files
are implemented for the Win 32 port of Bash, but I haven't run across the
documentation on how to do that yet.  Can anyone tell me where I can find
that info?

Len Sisson
Knoxville, TN

-
For help on using this list, send a message to
"gnu-win32-request@cygnus.com" with one line of text: "help".

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~1997-03-15  0:54 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
1997-03-14 21:00 Start-up files for bash? Boatwright, Charles
  -- strict thread matches above, loose matches on Subject: below --
1997-03-15  0:54 Weiqi Gao
1997-03-14  6:27 Leonard Sisson
1997-03-14 13:38 ` Ed Huott
1997-03-14 21:00 ` Horia F Pop
1997-03-14 21:00 ` Sheik

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).