delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2012/07/08/16:27:33

X-Recipient: archive-cygwin AT delorie DOT com
X-SWARE-Spam-Status: No, hits=-5.9 required=5.0 tests=AWL,BAYES_00,DKIM_SIGNED,DKIM_VALID,DKIM_VALID_AU,FREEMAIL_FROM,KHOP_RCVD_TRUST,KHOP_THREADED,RCVD_IN_DNSWL_LOW,RCVD_IN_HOSTKARMA_YE
X-Spam-Check-By: sourceware.org
Message-ID: <4FF9ED18.4080006@gmail.com>
Date: Sun, 08 Jul 2012 22:27:04 +0200
From: marco atzeri <marco DOT atzeri AT gmail DOT com>
User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64; rv:13.0) Gecko/20120614 Thunderbird/13.0.1
MIME-Version: 1.0
To: cygwin AT cygwin DOT com
Subject: Re: Inconsistence on file operation when the name already exists with exe extension
References: <BLU152-W250F4120B3650DBD65E5D2CEEC0 AT phx DOT gbl> <BLU152-W26F54627DEBFF08480143BCEEC0 AT phx DOT gbl>
In-Reply-To: <BLU152-W26F54627DEBFF08480143BCEEC0@phx.gbl>
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

On 7/8/2012 10:19 PM, Aaron Schneider wrote:
>
> --On an empty dir--:
>
> touch file.exe
>
> touch file.img
>
> touch file doesn't create the corresponding file.
>
> --Then--
>
> touch helpp
>
> cp helpp file
>
> cp: can't create regular file «file»: File exists
>
> On rm file it removes the file.exe instead of saying file not found.
>
> Is this behavior intended? This is not unix like, the filename should be preserved as is
>   		 	   		

In a normal unix, programs do not need the exe suffix so on cygwin
  "file.exe" can be referred as  "file".

"file" is the unix way
"file.exe" is the windows way

Try:
$ cd /bin
$ ls -l bash
$ ls -l bash*

as such you can not have a second file or directory with the same name.

Regards
Marco





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