X-Recipient: archive-cygwin AT delorie DOT com X-SWARE-Spam-Status: No, hits=-1.8 required=5.0 tests=AWL,BAYES_00,SARE_MSGID_LONG40,SPF_PASS X-Spam-Check-By: sourceware.org MIME-Version: 1.0 In-Reply-To: <4A2E931C.7070700@smart.net> References: <4A2E290B DOT 6040809 AT gmail DOT com> <4A2E931C DOT 7070700 AT smart DOT net> Date: Tue, 9 Jun 2009 13:15:06 -0400 Message-ID: Subject: Re: Why sh failed 'Process Substitution'? From: "Mark J. Reed" To: cygwin AT cygwin DOT com Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-IsSubscribed: yes Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm Precedence: bulk List-Id: List-Unsubscribe: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: cygwin-owner AT cygwin DOT com Mail-Followup-To: cygwin AT cygwin DOT com Delivered-To: mailing list cygwin AT cygwin DOT com >> Pan ruochen wrote: >>> Why sh failed to recognize Process Substitution, even if /bin/sh.exe >>> is a copy of /bin/bash.exe? It's very common in UNIXland for a program to change its behavior depending on the name by which it is invoked. ln, mv, and rm are often links to the same command; there's at least one embedded UNIXalike where all the commands in /bin are links to the same executable. The script has a #!/bin/bash at the top, indicating that it is meant to be run by bash in bash mode. If you make it executable and run it directly, that line will be honored and the shell will be invoked as bash. Or you can run it by typing "bash ./scriptname". None of this, of course, is at all Cygwin-specific. -- Mark J. Reed -- 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/