Re:What's New in POSIX 2024
by curt15 on Tuesday October 29, 2024 @07:23AM
(#41982730)
Didn't Windows name "Program Files" with a space to force application developers to handle spaces in paths properly?
[ Parent
| on HN ]
Not to mention C:\Program Files (x86)
And C:\Programme and other localized variants to force people to go through the proper APIs instead of hardcoding paths.
In theory yes, in practice to this day many people don't bother how to learn how to deal with pathnames in a proper way.
Top difficulties in computer science:
1. naming things
2. cache coherency
3. off-by-one errors
???
4. quoting pathnames
I would replace 4 with parameter expansion rules.
Eh, maybe. In practice I usually do all my moderately-heavy filesystem scripting in Python these days, for which pathname quoting is just a complete non-issue. Of course, I still use a shell for quick-and-dirty stuff, but usually only for pretty simple tasks where the simplest quoting setup ("$i") suffices.
Re:What's New in POSIX 2024
by mmcdermott on Tuesday October 29, 2024 @12:04PM
(#41985632)
For the longest time you could get away with this in cmd:
> dir c:\progra~1
So if forcing people to handle spaces was the goal, it took a long time to force it.
I'm pretty sure that still works. I forgot the exact scenario, but my Windows CI on GitHub Actions output shorte~1 pathna~1 like that in a script just a few months ago. On one hand, the backwa~1 compati~1 is nice. On the other hand, there's just so much depreca~1 cruft that keeps popping up even on contemp~1 systems.
Re:What's New in POSIX 2024
by InfiniteRand on Tuesday October 29, 2024 @04:50PM
(#41989244)
I just got used to installing things I need to interact with in a program into a folder named C:\workspace