bug-coreutils
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#21325: ls : feature request --width=zero


From: Beco
Subject: bug#21325: ls : feature request --width=zero
Date: Sat, 22 Aug 2015 21:01:47 -0300

Dear developers,

I'm writing to ask for a small change in an already existing feature of "ls" command.

The switch is: -w, --width=COLS

Let it be possible to state size ZERO as being "infinity", for example:

(A)
ls -m -w0

(B)
ls -x --width=0

That will ensure that:

ls -m -w0 | wc -l
1

Meaning that ls will output a single line.

For now a workaround is just use a very big number for width, say -w10000, but this hack must be checked beforehand in any directory.

LSSIZE=1000; test $(ls -x -w$LSSIZE | wc -l) == 1 && echo size $LSSIZE ok || echo size $LSSIZE not ok

I hope :

* I could inspire you to understand the easy modification that's asked
* the usefulness of the modification

Thanks,
Beco


--
Dr Beco
A.I. researcher

"I know you think you understand what you thought I said but I'm not sure you realize that what you heard is not what I meant" -- Alan Greenspan

Creation date: pgp.mit.edu ID as of 2014-11-09

reply via email to

[Prev in Thread] Current Thread [Next in Thread]