public inbox for cygwin@cygwin.com
 help / color / mirror / Atom feed
From: Aaron Schneider <notstop@users.sourceforge.net>
To: cygwin@cygwin.com
Subject: Re: Inconsistence on file operation when the name already exists with exe extension
Date: Mon, 09 Jul 2012 17:20:00 -0000	[thread overview]
Message-ID: <BLU0-SMTP224D901B80815ECFB99E3BCED30@phx.gbl> (raw)
In-Reply-To: <20120709154456.GA6696@ednor.casa.cgf.cx>

On 09/07/2012 17:44, Christopher Faylor wrote:
> On Mon, Jul 09, 2012 at 05:23:13PM +0200, notstop wrote:
>> You must be right in some points, but that is not the exact behavior of
>> windows command although you pretend it to be (the powershell has a
>> different behavior). In fact, I can independently operate file while
>> file.exe exists:
>>
>> copy file.exe file
>> Now there are file and file.exe
>
> Common email practice is to include the text of the email you are
> responding to so that we can know who you are accusing of "pretending".
>
> Nevertheless, FYI, powershell is not Cygwin and no one is saying that
> the behavior you're seeing is mandated by Windows.  What you are seeing
> is a Cygwin accommodation for the fact that .exe is a special extension.
> Cygwin is not a new project.  Its handling of .exe has been hashed and
> rehashed throughout the life of the project.  The current behavior is
> the compromise that we've settled on.
>
> So, what you are seeing is expected.  Continuing to argue without
> familiarizing yourself with past discussions is not likely to expose
> anything new.
>
> --
> 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
>
>

Sorry for not quoting, server was including raw email addresses in reply 
and got several bounces.

About the issue

-- There is something I need to clarify about what I am referring to 
with windows shells --:

* Windows command is %SystemRoot%\System32\cmd.exe
* Windows Powershell is included by default in Windows 7 at 
%SystemRoot%\system32\WindowsPowerShell\v1.0\powershell.exe

I believe that Cygwin tries to emulate cmd.exe

-- They both behave differently --.

For example when typing file.exe on a directory:

* powershell tries to locate the executable in PATH at any costs 
regardless if exists in present directory. In fact if exists, won't 
execute it directly, will give error "Suggestion [3,General]: The 
command file.exe was not found, but does exist in the current location. 
Windows PowerShell doesn't load commands from the current location by 
default. If you trust this command, instead type ".\file.exe"." and will 
force you to run .\file.exe

* cmd.exe will run the file.exe if exists in present directory, without 
the need to run it as .\file.exe ; if not will run from path environment 
variable.

** Other differences may exist.

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

  parent reply	other threads:[~2012-07-09 17:20 UTC|newest]

Thread overview: 20+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-07-09 15:23 notstop
2012-07-09 15:45 ` Christopher Faylor
2012-07-09 16:47   ` Steven Hartland
2012-07-09 17:20   ` Aaron Schneider [this message]
2012-07-10  5:38     ` Matt Seitz
2012-07-10  8:45       ` Aaron Schneider
2012-07-10 15:25         ` Earnie Boyd
2012-07-10 16:23           ` Larry Hall (Cygwin)
2012-07-10 16:54           ` Aaron Schneider
2012-07-10 17:03             ` Christopher Faylor
2012-07-10 18:59             ` Earnie Boyd
2012-07-11  0:50             ` Andrey Repin
  -- strict thread matches above, loose matches on Subject: below --
2012-07-08 20:03 Aaron Schneider
2012-07-08 20:19 ` Aaron Schneider
2012-07-08 20:27   ` marco atzeri
2012-07-08 20:37     ` Aaron Schneider
2012-07-09 12:36       ` Earnie Boyd
2012-07-08 20:49     ` Aaron Schneider
2012-07-08 22:43   ` Buchbinder, Barry (NIH/NIAID) [E]
2012-07-08 23:20   ` Andrey Repin

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=BLU0-SMTP224D901B80815ECFB99E3BCED30@phx.gbl \
    --to=notstop@users.sourceforge.net \
    --cc=cygwin@cygwin.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).