This is the mail archive of the
cygwin
mailing list for the Cygwin project.
Re: Force "ls" to show .exe extension
- From: Paul <Paul dot Domaskis at gmail dot com>
- To: cygwin at cygwin dot com
- Date: Wed, 7 Jan 2015 16:07:54 +0000 (UTC)
- Subject: Re: Force "ls" to show .exe extension
- Authentication-results: sourceware.org; auth=none
- References: <loom dot 20150106T203355-631 at post dot gmane dot org> <1941710256 dot 20150107013212 at yandex dot ru> <loom dot 20150107T010713-891 at post dot gmane dot org> <6CF2FC1279D0844C9357664DC5A08BA20FA979B4 at msgb09 dot nih dot gov>
Buchbinder, Barry (NIH/NIAID) [E] <BBuchbinder <at> niaid.nih.gov> writes:
>Paul sent the following at Tuesday, January 06, 2015 7:12 PM
>> I'm wading through many files in two file trees. In particular, I'm
>> looking at corresponding directories in the two trees where "diff
>> -qr" revealed differences. I want the absolute truth of what the
>> filename is with minimal distractions about how to achieve that.
>> Then, I can focus on figuring how those files came about, and how
>> the differences arose.
>
> Not a Cygwin solution but the following should give real names.
>
> cmd /c dir /b /a:
>
> (The /a: makes sure that hidden files are listed.)
That works great, Barry. The following also works:
cmd /c dir /b /a: | dos2unix | xargs ls -ltd
However, variation#1
type -pa pdfcrop | xargs cmd /c dir /b /a:
doesn't work because dir expects DOS filenames (I suspect).
Variation#2
type -pa pdfcrop | xargs cygpath -aw | xargs cmd /c dir /b /a:
doesn't work because the backward slashes are interpretted by Escapes
by bash.
Variation#3 (on *one* line):
type -pa pdfcrop | xargs cygpath -aw -t mixed | xargs cmd /c dir /b
/a:
doesn't work because
Parameter format not correct - "cygwin64"
To find out what was going on, I stuck an "echo" in front of cmd,
which yielded the following (on *one* line):
cmd /c dir /b /a: C:/cygwin64/home/User.Name/bin/pdfcrop
C:/cygwin64/usr/share/texmf-dist/scripts/pdfcrop/pdfcrop.pl
C:/cygwin64/usr/share/texmf-dist/scripts/pdfcrop/pdfcrop.pl
I think the dir command is interpreting /cygwin64 as a command switch.
--
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