This is the mail archive of the
mailing list for the Cygwin project.
Re: "bash: hello: Command not found" error for hello.exe in present directory
- From: "Terry Flannery" <terry dot flannery at btinternet dot com>
- To: "Abhijit Patait" <abhijit_patait at yahoo dot com>,<cygwin at cygwin dot com>
- Date: Sun, 18 Aug 2002 22:09:01 +0100
- Subject: Re: "bash: hello: Command not found" error for hello.exe in present directory
- References: <email@example.com>
Your windows 2000 machine has . in your path then, which is not done by
----- Original Message -----
From: "Abhijit Patait" <firstname.lastname@example.org>
Sent: Sunday, August 18, 2002 10:04 PM
Subject: Re: "bash: hello: Command not found" error for hello.exe in present
> This, however, does not happen on the cygwin bash
> shell installed on my Windows 2000 machine (I did not
> do anything special there). That's why I am confused!!
> Because unlike DOS and NT command shells, bash et.al.
> do NOT look for any executables in the current
> directory unless explicitly told to do so (by
> prepending './' to the command or adding '.' to the
> Abhijit Patait wrote:
> I recently installed cygwin on my Windows XP machine.
> I wrote a simple "hello world" program and compiled
> and linked it using gcc to create an executable named
> "hello.exe" in a directory, named ~/hello/. However,
> when I type "hello.exe" on the command line (in the
> directory ~/hello/), I get a "bash: hello: command not
> found" error. I have verified that the file hello.exe
> exists in that directory.
> A workaround is that I have to issue a command
> "./hello" and then it works. Another workaround is
> that I append "./" to my path in the .bashrc file in
> my home directory and then it works too. Could someone
> shed light on what's going on? Why is the shell not
> able to look for the command in the present directory
> Thanks in advance for your help.
> Do You Yahoo!?
> HotJobs - Search Thousands of New Jobs
> 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/
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
Bug reporting: http://cygwin.com/bugs.html