I discovered this change today while playing with a “modern” Linux install, and I’m unreasonably upset about it. https://unix.stackexchange.com/questions/258679/why-is-ls-suddenly-wrapping-items-with-spaces-in-single-quotes
Why is 'ls' suddenly wrapping items with spaces in single quotes?

I just noticed that on one of my machines (running Debian Sid) whenever I type ls any file name with spaces has single quotes surrounding it. I immediately checked my aliases, only to find them int...

Unix & Linux Stack Exchange
@siracusa yeah. I don’t like that at all.
@siracusa is it only when outputting to the terminal? Or when you pipe it, too?
@cmaier I don’t know.
@siracusa @cmaier piping and scripts look to be “safe”:
$ touch ls\ test
$ ls ls\ test
'ls test'
$ ls ls\ test | cat
ls test
$ ls -N ls\ test
ls test

@cmaier @siracusa According to one of the answers, only to terminals.

https://unix.stackexchange.com/a/258691

Why is 'ls' suddenly wrapping items with spaces in single quotes?

I just noticed that on one of my machines (running Debian Sid) whenever I type ls any file name with spaces has single quotes surrounding it. I immediately checked my aliases, only to find them int...

Unix & Linux Stack Exchange
@tylermumford @siracusa That’s slightly less annoying, I guess.
@siracusa If I ran Linux anywhere that mattered, I'd quit running Linux over that kind of nonsense!
#freebsd
@siracusa Unpopular opinion: This change is, on balance, good. “Oops I used the output of ls” is a time-honored rake for new unix users to step on.
@njvack @siracusa unpopular opinion: this is why powershell should replace bash

@joeld @njvack @siracusa I second this unpopular opinion, partially because it would make it easier to go cross-platform without needing WSL or anything of that ilk.

But seeing as we are where we are… I’m learning how to parse output from find instead of ls and my life is better for it.

@atomicangel @joeld @siracusa it's bonkers how many awful characters are allowed in posix filenames. Quotes? Globbing characters? Newlines? Have at it.

`find -print0 | xargs -0` is the way

@joeld @siracusa wait what you can install powershell on linux??
Install PowerShell on Linux - PowerShell

Learn about the Linux distributions supported by PowerShell.

@siracusa
Funny, I so infrequently use spaces in file names that I hadn't actually noticed said behavior until reading this post.

Naturally, now that I'm aware of it, it's going to bother me without end...

@siracusa this… this is from seven years ago?

Your Synology does this, I can attest

@siracusa (though what I’d like is the opposite, better machine output. Would be nice for everything to support -0 like e.g. xargs does)
@jason @siracusa one should use `find` instead of `ls` for scripting
.@siracusa Reading the coreutils devs explanation (that has to be a tough call to go ahead and implement) it seems… pretty reasonable (to disagree about) since it’s intended not to harm script behavior and wants to make things ‘safer’/more predictable for less savvy users copying and pasting
(I appreciate the heads up, the devtools team people at work install all the gnu versions on macs via homebrew so it could lead to uncertainty and debatable effort on patching aliases)
@Arubdesu @siracusa yes, this. I was annoyed initially because things changed and I was used to the other way. But the reasoning absolutely makes sense.
@vnkr I’m more than willing to appreciate and gauge the impact/cost of cognitive switching, but being an open source booster (especially of maintainers) I also try to take the tact that actual action/change is rare and severely difficult and couldn’t have been approached lightly, so they earn just as much empathy since they’re outnumbered 😅😬
@siracusa It is also shocking that standard shells don’t have first class support for retrieving a file list. We’ve only had 5+ decades to figure this out 😩
@siracusa I actually feel like the old behavior (no quotes) is one of the key reasons I learned to use find over piping the output of ls scripts. So overall, I think this is okay in my book
@siracusa time to try OpenBSD? A mature, stable, secure OS guided by a strongly opinionated (and usually right) hand
@siracusa wow, I'd forgotten I was mad about this. It's utterly absurd.
@siracusa it doesn’t matter that this article is 7 years old. The fact that somebody decided it was a good idea at all is timelessly stupefying. FreeBSD FTW once again.
@siracusa now I’m unreasonably upset at 6:30am
@siracusa I haven’t really used Linux in years, and I’m getting annoyed by this already…