Subject: Re: Incorrect expansion of a program argument that is a special character?
From: Brian Inglis <[email-masked]>
To: [email-masked]
Cc: Ev Drikos <[email-masked]>
Date: Wed, 21 Jul 2021 09:44:51 -0600
List-Id: General Cygwin discussions and problem reports <cygwin.cygwin.com>

On 2021-07-21 05:42, Ev Drikos via Cygwin wrote:
> When I run the program below from my home directory in a PowerShell
> Console (Windows 8-1) I've to use an extra backslash character as
> shown below or the star is expanded. Which happens only when the
> program has been compiled in Cygwin.
> 
> Is this a bug or a known feature?

It's a feature which emulates the argument expansions normally performed 
by shells under Unix like systems.
If a Cygwin program is not run from a Cygwin shell, then the Cygwin 
program startup argument parsing obeys the quoting rules and performs 
the argument expansions which running from a Cygwin shell would normally 
perform, so the program sees the same arguments as running from a Cygwin 
shell would generate.

Run "info bash 'pattern matching'" then press u (Up) and repeat to see 
other argument expansions and processing performed; tab and press Enter 
to view Topics; press q to Quit.

-- 
Take care. Thanks, Brian Inglis, Calgary, Alberta, Canada

This email may be disturbing to some readers as it contains
too much technical detail. Reader discretion is advised.
[Data in binary units and prefixes, physical quantities in SI.]

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