X-Spam-Check-By: sourceware.org
Message-ID: <43DF8DF4.5080105@opnet.com>
Date: Tue, 31 Jan 2006 17:19:00 +0100
From: Stein Somers <ssomers@opnet.com>
User-Agent: Mozilla Thunderbird 1.0.6 (Windows/20050716)
MIME-Version: 1.0
To: cygwin@cygwin.com
Subject: Re: Using grep from within a .cmd or .bat file in Windows
References: <loom.20060131T164649-334@post.gmane.org> <43DF8C11.1000307@exmsft.com>
In-Reply-To: <43DF8C11.1000307@exmsft.com>
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit
X-OPNET-MailScanner: Found to be clean
X-IsSubscribed: yes
Mailing-List: contact cygwin-help@cygwin.com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe@cygwin.com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin@cygwin.com>
List-Help: <mailto:cygwin-help@cygwin.com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner@cygwin.com
Mail-Followup-To: cygwin@cygwin.com
Delivered-To: mailing list cygwin@cygwin.com

Keith Moore wrote:
> Tzuriel wrote:
> 
> 
>>grep --help
>>pause
>>
>>inside a file called grep.cmd,
> 
> 
> "grep.cmd" is getting executed recursively. You
> need to name your .cmd file something other than
> "grep".

Or invoke "grep.exe --help".  Or if you want to experiment, specify the exact path to grep.  Or 
if you love to experiment, make sure grep.cmd is not in the current directory and not in any 
PATH entry, so that you have to invoke it with an explicit path.

Stein

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

