delorie.com/archives/browse.cgi | search |
Mailing-List: | contact cygwin-help AT sourceware DOT cygnus DOT com; run by ezmlm |
List-Subscribe: | <mailto:cygwin-subscribe AT sources DOT redhat DOT com> |
List-Archive: | <http://sources.redhat.com/ml/cygwin/> |
List-Post: | <mailto:cygwin AT sources DOT redhat DOT com> |
List-Help: | <mailto:cygwin-help AT sources DOT redhat DOT com>, <http://sources.redhat.com/ml/#faqs> |
Sender: | cygwin-owner AT sources DOT redhat DOT com |
Delivered-To: | mailing list cygwin AT sources DOT redhat DOT com |
X-Authentication-Warning: | ics-server.interface-net.com: lbakken owned process doing -bs |
Date: | Fri, 22 Sep 2000 09:39:35 -0700 (PDT) |
From: | Luke Bakken <luke_bakken AT yahoo DOT com> |
X-Sender: | lbakken AT ics-server DOT interface-net DOT com |
Reply-To: | luke_bakken AT yahoo DOT com |
To: | Jonathan Segal <jonathan DOT segal AT genomecorp DOT com> |
cc: | cygwin AT sources DOT redhat DOT com |
Subject: | Re: Bash + Shell hack = ? |
In-Reply-To: | <39CB8334.35C6BFF5@genomecorp.com> |
Message-ID: | <Pine.BSO.4.21.0009220936320.21338-100000@ics-server.interface-net.com> |
MIME-Version: | 1.0 |
This is what I had to do with this: c:\cygwin\bin\bash.exe -c "cd '%1';exec /usr/bin/bash --rcfile /home/administrator/.bash_shell_profile" I had to create that separate rcfile since the /etc/profile file has a cd $HOME in it - i removed that from this one to keep it from cd'ing to /home/administrator every time, and I can still start up bash the normal way (ie the Cygwin icon) and be taken to my home dir. Thanks for the suggestion - it steered me in the right way!! Luke On Fri, 22 Sep 2000, Jonathan Segal wrote: > Neat idea! > > To do this with bash, try something like > > d:\cygwin\bin\bash.exe -c "cd %1; exec /usr/bin/bash -i" > > replace d:\cygwin\bin with wherever bash is on your system. > > Enjoy, > -Jonathan > > Luke Bakken wrote: > > > Hi, > > > > I've got an option for my "File Folder" file type so that if I right-click > > on a folder, I can execute a cmd.exe prompt in that folder: > > > > cmd.exe /K cd "%1" > > > > What I'm wondering is if something analogous to the /K switch exists for > > Bash, so that I can run a command before starting the login shell. the > > "-c" option is similar, but the shell exits after running the command > > specified. What I want is for it not to exit. > > > > Thanks, > > Luke > > > > -- > > Want to unsubscribe from this list? > > Send a message to cygwin-unsubscribe AT sourceware DOT cygnus DOT com > > -- > Jonathan Segal > Principal Software Engineer/Group Leader, Bioinformatics > Genome Therapeutics Corp. > jonathan DOT segal AT genomecorp DOT com > (781) 398-2579 > -- Want to unsubscribe from this list? Send a message to cygwin-unsubscribe AT sourceware DOT cygnus DOT com
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |