starting cygwin shell

2013-04-07 Thread Gene
Hello Forum,
I am new to cygwin.
I am trying to create a .bat file so I can start cygwin from w7 windows menu.
I am looking for next:
1. new shell is created with next prompts:
gene@len /cygdrive/c
$

2. Backspace and arrow keys can move cursor to beginning.

At the default installation, I can only get this type of shell if I run 2 steps:
1. c:\cygwin\cygwin.bat
2. and in new shell I run: start bash.


Second question:

I am running below code and shell dissapear. 
I could catch the message before it happens. Do you know what seems to be a
problem?

for k in `ls`
do
print here is $k
done

Message: 

save: fork_level=1 SetHandleInformation() failed: fd 0 handle 0x3 type 2: Th
e parameter is incorrect.


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



Re: starting cygwin shell

2013-04-07 Thread Thomas Wolff

Am 07.04.2013 09:42, schrieb Gene:

Hello Forum,
I am new to cygwin.
I am trying to create a .bat file so I can start cygwin from w7 windows menu.
Cygwin install creates a Cygwin Terminal icon on your desktop in in 
your Programs menu. You can drag or (with Control-) copy it anywhere in 
menus where you want it. Is that what you need?



...

(unclear)


Second question:

I am running below code and shell dissapear.
I could catch the message before it happens. Do you know what seems to be a
problem?

for k in `ls`
do
print here is $k
done

$ type print
print ist /cygdrive/c/WINDOWS/system32/print
So you effectively tried to print files called here is ... with a 
Windows tool.

You probably meant this instead:
echo here is $k

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



Re: starting cygwin shell

2013-04-07 Thread Gene
Thomas Wolff towo at towo.net writes:

 
 Am 07.04.2013 09:42, schrieb Gene:
  Hello Forum,
  I am new to cygwin.
  I am trying to create a .bat file so I can start cygwin from w7 windows
menu.
 Cygwin install creates a Cygwin Terminal icon on your desktop in in 
 your Programs menu. You can drag or (with Control-) copy it anywhere in 
 menus where you want it. Is that what you need?
 
  ...
 (unclear)
 
  Second question:
 
  I am running below code and shell dissapear.
  I could catch the message before it happens. Do you know what seems to be a
  problem?
 
  for k in `ls`
  do
  print here is $k
  done
 $ type print
 print ist /cygdrive/c/WINDOWS/system32/print
 So you effectively tried to print files called here is ... with a 
 Windows tool.
 You probably meant this instead:
 echo here is $k
 
 

Yes, script should be as below.
However, the question is: if it's w7 compatible, why it's going down.
I was able to catch the message:

save: fork_level=1 SetHandleInformation() failed: fd 0 handle 0x3 type 2: Th
e parameter is incorrect.

for k in `ls`
do
print here is $k
done






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



Re: starting cygwin shell

2013-04-07 Thread Christopher Faylor
On Sun, Apr 07, 2013 at 06:16:17PM +, Gene wrote:
Thomas Wolff towo at towo.net writes:
 Am 07.04.2013 09:42, schrieb Gene:
I am new to cygwin.  I am trying to create a .bat file so I can start
cygwin from w7 windows menu.
Cygwin install creates a Cygwin Terminal icon on your desktop in in
your Programs menu.  You can drag or (with Control-) copy it anywhere
in menus where you want it.  Is that what you need?

Second question:

I am running below code and shell dissapear.  I could catch the message
before it happens.  Do you know what seems to be a problem?

for k in `ls` do print here is $k done
$ type print print ist /cygdrive/c/WINDOWS/system32/print So you
effectively tried to print files called here is ... with a Windows
tool.  You probably meant this instead: echo here is $k

Yes, script should be as below.  However, the question is: if it's w7
compatible, why it's going down.  I was able to catch the message:

save: fork_level=1 SetHandleInformation() failed: fd 0 handle 0x3 type
2: Th e parameter is incorrect.

That error message doesn't seem to be coming from Cygwin.  I have
grepped the Cygwin DLL and *sh* and don't see it anywhere.

Are you possibly using other binaries besides Cygwin ones?

See also:  http://cygwin.com/problems.html .

cgf

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



Re: starting cygwin shell

2013-04-07 Thread Dave Korn
On 07/04/2013 19:50, Christopher Faylor wrote:
 On Sun, Apr 07, 2013 at 06:16:17PM +, Gene wrote:

 save: fork_level=1 SetHandleInformation() failed: fd 0 handle 0x3 type
 2: Th e parameter is incorrect.
 
 That error message doesn't seem to be coming from Cygwin.  I have
 grepped the Cygwin DLL and *sh* and don't see it anywhere.
 
 Are you possibly using other binaries besides Cygwin ones?

  A quick google suggests it comes from MKS.  Trying to mix Cygwin tools and
MKS ones at the same time won't generally work well, and is probably the cause
of the shell problems too - MKS apparently is known to have problems under Win7.

  Gene, try removing MKS from your PATH setting.

cheers,
  DaveK


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



Re: Error when starting Cygwin shell: init_cygheap error

2002-03-04 Thread Larry Hall (RFK Partners, Inc)

At 08:53 PM 3/1/2002, Stan Berka wrote:
BTW, when I do which cygwin1.dll from the shell it tells me: 
/usr/bin/cygwin1.dll
There is no /usr/bin.  Is this a part of the problem?

I doubt it.  Try typing 'mount' and see if there is a /usr/bin listed 
there.  If not, rerun setup.  It creates the /usr/bin mount point, as
well as making sure your system has a valid installation. 


Larry Hall  [EMAIL PROTECTED]
RFK Partners, Inc.  http://www.rfk.com
838 Washington Street   (508) 893-9779 - RFK Office
Holliston, MA 01746 (508) 893-9889 - FAX


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Bug reporting: http://cygwin.com/bugs.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/




Error when starting Cygwin shell: init_cygheap error

2002-03-01 Thread Stan Berka

Hi,
I have the same problem as in the January thread cited below: 

when starting the Cygwin shell I'm getting an error:

   9 [main] bash 2040 init_cygheap::etc_changed: Can't open /etc for  
checking, Win32 error 1

I have checked that I don't have two cygwin1.dll in my PATH. When I
rename the cygwin1.dll in the /bin directory to something else, I'm
getting a message that cygwin1.dll is missing. So what can be the
problem?

BTW, when I do which cygwin1.dll from the shell it tells me: 
/usr/bin/cygwin1.dll
There is no /usr/bin.  Is this a part of the problem?

Stan Berka, Pope  Talbot Inc.

 Thread about the same problem 
From: Corinna Vinschen 
To: cygwin at cygwin dot com
Date: Thu, 10 Jan 2002 15:08:51 +0100
Subject: Re: Cygwin 1.3.6 on NT 4.0: init_cygheap error
References: [EMAIL PROTECTED]
[EMAIL PROTECTED]

On Thu, Jan 10, 2002 at 03:01:12PM +0100, Pavel Tsekov wrote:
 Markus Brenner wrote:
 For compatibility and historical reasons the B20 release is also 
installed
 on the same machine (I am not sure whether this has any influence on the
 above described problem).


 This is not good. I'm not 100 % sure if this is connected to your
^
Right! Never have two copies of cygwin1.dll in the DLL search path.
Even worse if they have diverging versions.
Corinna
--


--
Unsubscribe info:  http://cygwin.com/ml/#unsubscribe-simple
Bug reporting: http://cygwin.com/bugs.html
Documentation: http://cygwin.com/docs.html
FAQ:   http://cygwin.com/faq/