delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2013/02/13/11:14:32

X-Recipient: archive-cygwin AT delorie DOT com
X-SWARE-Spam-Status: No, hits=-2.3 required=5.0 tests=AWL,BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM,KHOP_RCVD_TRUST,KHOP_SPAMHAUS_DROP,RCVD_IN_DNSWL_LOW,RCVD_IN_HOSTKARMA_NO
X-Spam-Check-By: sourceware.org
Message-ID: <511BBBD4.8090902@fastmail.fm>
Date: Wed, 13 Feb 2013 11:14:12 -0500
From: Jack Radigan <jprad AT fastmail DOT fm>
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:17.0) Gecko/20130106 Thunderbird/17.0.2
MIME-Version: 1.0
To: cygwin AT cygwin DOT com
Subject: Is this a bug or a behavior?
X-IsSubscribed: yes
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com

Using the following script:
#!/bin/bash
set -x
cat << eof | `ls /bin | grep "^grep$"` alpha
alpha
omega
eof

Output from bash on Linux:
+ cat
++ ls /bin
++ grep '^grep$'
+ grep alpha
alpha

Output from bash on Cygwin:
+ cat
++ ls /bin
++ grep '^grep$'
+ alpha
./ls-test: line 3: alpha: command not found

But, the command 'cp /bin/grep ~/.' will copy grep.exe to my home directory.

Shouldn't 'ls' be suppressing the '.exe' extension for cygwin binaries 
in the same way that 'cp' appends it?

Seems inconsistent not to.

--
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

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019