Discussion:
bug#32774: Filenames with spaces in ls
(too old to reply)
Ivan Perez
2018-09-19 19:01:44 UTC
Permalink
Hi,

In a fresh Ubuntu installation, file names with spaces and strange
symbols are now quoted.

If find this annoying, non-intuitive and, in principle, wrong (I'll
explain below).

I initially wrote this email a few weeks ago, and decided not to send it
without honestly giving it a real try. Since it's been over a month now,
I've decided to send it.

I understand that this is configurable for ls, but that means, every
time or every user needs to do this. It is difficult to understand how
many people are for or against. There's always a couple of people in
favour of it in the mailing list, and a lot against (but I acknowledge
that that may not reflect the true proportion).

The new behaviour can be annoying, and can make it harder to process
information quickly. This may be a matter of preference, but the
presence of the extra quote and the misalignment that that causes draws
one's attention to the quote. File names with similar but related names
no longer appear aligned in ls which, again, draws attention to the
quote when one is processing long lists of files. It also makes names
with quotes pretty hard to understand.

I have read about the reasons *for* doing this. While the new behaviour
helps copy & paste, it's counter intuitive, because the symbol is not
part of the name (but it could be).

Ultimately, the rationale could be simpler: the quote symbol is *just
not there in the file name*.

Please, make literal the default for ls (and any other program that may
be affected by this).

All the best,

Ivan
Paul Eggert
2018-09-19 19:46:01 UTC
Permalink
the presence of the extra quote and the misalignment that that causes draws
one's attention to the quote.
That's part of the intent. The quotes draw the reader's attention to the oddball
file name, which is a good thing since these file names can cause trouble when
they are cut and pasted from 'ls' output.
File names with similar but related names no longer appear aligned in ls
That depends on what one means by 'appear aligned'. In this 'ls -l' output:

-rw-rw-r--. 1 eggert eggert 0 Sep 19 12:39 a
-rw-rw-r--. 1 eggert eggert 0 Sep 19 12:39 'a b'
-rw-rw-r--. 1 eggert eggert 0 Sep 19 12:39 a-b

all three file names are aligned to start at the same screen column; there's a
column of 'a's that line up, and the quotes are not part of the quoted file
name. I prefer having file names aligned like that, and wouldn't favor aligning
the opening quote to be equal to the unquoted files' initial 'a's. Admittedly
preferences differ, but alignment is not really the issue here; it's the quotes
that people are largely objecting to.
Assaf Gordon
2018-10-30 03:58:46 UTC
Permalink
tags 32774 notabug
close 32774
stop
Post by Paul Eggert
the presence of the extra quote and the misalignment that that causes
draws one's attention to the quote.
That's part of the intent. The quotes draw the reader's attention to the
oddball file name, which is a good thing since these file names can
cause trouble when they are cut and pasted from 'ls' output.
Given the above, I'm closing this bug.

-assaf

Continue reading on narkive:
Loading...