From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: kg6mar@gmail.com Newsgroups: gmane.emacs.help Subject: Re: Dired confused by filenames starting with date-like strings Date: 24 Aug 2006 10:43:26 -0700 Organization: http://groups.google.com Message-ID: <1156441406.766871.297830@m73g2000cwd.googlegroups.com> References: <1156356934.469929.210320@i3g2000cwc.googlegroups.com> NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" X-Trace: sea.gmane.org 1156444845 31377 80.91.229.2 (24 Aug 2006 18:40:45 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Thu, 24 Aug 2006 18:40:45 +0000 (UTC) Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Thu Aug 24 20:40:44 2006 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by ciao.gmane.org with esmtp (Exim 4.43) id 1GGK7x-0006Cp-G6 for geh-help-gnu-emacs@m.gmane.org; Thu, 24 Aug 2006 20:40:29 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1GGK7w-0000L4-Fu for geh-help-gnu-emacs@m.gmane.org; Thu, 24 Aug 2006 14:40:28 -0400 Original-Path: shelby.stanford.edu!newsfeed.stanford.edu!postnews.google.com!m73g2000cwd.googlegroups.com!not-for-mail Original-Newsgroups: gnu.emacs.help Original-Lines: 42 Original-NNTP-Posting-Host: 70.191.48.113 Original-X-Trace: posting.google.com 1156441413 4880 127.0.0.1 (24 Aug 2006 17:43:33 GMT) Original-X-Complaints-To: groups-abuse@google.com Original-NNTP-Posting-Date: Thu, 24 Aug 2006 17:43:33 +0000 (UTC) User-Agent: G2/0.2 X-HTTP-UserAgent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.0.6) Gecko/20060728 Firefox/1.5.0.6,gzip(gfe),gzip(gfe) Complaints-To: groups-abuse@google.com Injection-Info: m73g2000cwd.googlegroups.com; posting-host=70.191.48.113; posting-account=aQP3-AwAAADkgdkfsEmf0-7Y_0gZlUvo Original-Xref: shelby.stanford.edu gnu.emacs.help:141291 Original-To: help-gnu-emacs@gnu.org X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:36913 Archived-At: Miles Bader wrote: > kg6mar@gmail.com writes: > > Dired gets confused by certain filenames in which the beginning > > resembles a date and there is an embedded space (my photograph naming > > convention). It fails to assemble the entire filename. > > This works correctly on my system, because dired invokes ls with the > "--dired" option (a feature of GNU ls, which causes ls to output extra > information about where the names are located). > > The variable `dired-use-ls-dired' controls whether dired does this or > not. So to fix this problem, try installing GNU ls (I guess that means > cygwin, as you're on ms-windows?) and setting dired-use-ls-dired to t. After more testing and advice-following, it still appears to me that ls is working as required, but dired can't parse this particular filename correctly from the ls output. It sounds as if it works on a Unix or linux emacs implementation but not Windows. - Emacs 21.3.1 for Windows doesn't appear to have a variable called dired-use-ls-dired, but I can set dired-listing-switches to "-lD" which invokes the ls --dired option, achieving the same purpose. - I verified that I'm using cygwin's ls. I tried the --dired option suggested here, with no different final result. I tested some more filenames. Of the following, the only one dired can't Copy or Rename correctly is the last (which it takes to be foo.txt). Again, the problematic name begins with a string that looks like a date, and has a space after that. These are cut and pasted from dired: -rw-rw-rw- 1 John root 3 Aug 23 19:34 2006-08-23.txt -rw-rw-rw- 1 John root 3 Aug 23 19:34 2006-08-23foo.txt -rw-rw-rw- 1 John root 3 Aug 23 19:34 foo 2006-08-23 foo.txt -rw-rw-rw- 1 John root 3 Aug 23 19:34 2006-08-23 foo.txt I appreciate your thinking here. -- John