How does one change the default shell?
Thu Sep 2 22:57:00 GMT 2010

[ACK!  I just realized I was continuing my usurping of the thread. Sorry.]

>On 09/02/2010 04:29 PM, wrote:
>> I use pdksh as my login shell - I have been using the Korn shell 
>> Dave!) since 1984 or so, so it is what I am used to and has features I
>> haven't been able to find in bash - at least not yet.  So to expedite
>> script writing, I use the ksh language and features  Every time that I
>> write a script, I have to remember to put in the shebang line
>> (#!/bin/pdksh) or half the time my scripts won't work.
>> Is there a way to change the default shell for cygwin?  I checked the 
>> guide and the FAQ, but no joy there.  I tried setting and exporting the
>> SHELL variable, but that did not work.
>Assuming you meant the default shell for your particular user id, it is 
>just a matter of changing cygwin.bat or whatever shortcut you are using 
>to start cygwin to call pdksh instead of bash.  You can also edit 
>/etc/passwd to set your preferred shell (some tools, like mintty, honor 
>that setting).

My /etc/passwd entry:


My cygwin.bat:

@echo off

chdir C:\cygwin\bin

REM bash --login -i
REM pdksh -l -i
start mintty -p 70,0 -t Console -e -

This starts me off in pdksh, but when I execute a shell script, it runs 
under bash.

Any other ideas?


- Phil

I did not realize I was commandeering the thread.  My apologies - it won't 
happen again.

Problem reports:
Unsubscribe info:

More information about the Cygwin mailing list