GNU bug report logs -
#18875
25.0.50; Dired -- add support for ls --time-style with a space
Previous Next
Reported by: Keith David Bershatsky <esq <at> lawlist.com>
Date: Tue, 28 Oct 2014 16:45:02 UTC
Severity: minor
Found in version 25.0.50
Done: Lars Ingebrigtsen <larsi <at> gnus.org>
Bug is archived. No further changes may be made.
Full log
View this message in rfc822 format
Keith David Bershatsky <esq <at> lawlist.com> writes:
> Thank you, Eli, for taking a look at this report (#18875).
>
> `hour:minute:seconds` is omitted because there is a space between the
> date and the time.
>
> C-u C-x d
>
> -alh --group-directories-first --time-style=+%m-%d-%Y %H:%M:%S
(I'm going through old bug reports that unfortunately weren't resolved
at the time.)
These are things that has to be understandable to the shell, so you have
to quote things appropriately for the shell.
So I'd expect this to work:
C-u C-x d
-alh --group-directories-first --time-style="+%m-%d-%Y %H:%M:%S"
But it doesn't;
(insert-directory "/tmp/" "-alh --time-style=\"+%m-%d-%Y %H:%M:%S\"")
fails.
(split-string-and-unquote "-alh --time-style=\"+%m-%d-%Y %H:%M:%S\"")
=> ("-alh" "--time-style=" "+%m-%d-%Y %H:%M:%S")
However, this works:
(insert-directory "/tmp/" "-alh \"--time-style=+%m-%d-%Y %H:%M:%S\"")
So... dired supports spaces in command line arguments, but you have to
quote the argument, so I'm closing this bug report. However, there's a
bug in `split-string-and-unquote', so I'm opening a new report for that.
--
(domestic pets only, the antidote for overdose, milk.)
bloggy blog: http://lars.ingebrigtsen.no
This bug report was last modified 3 years and 278 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.