Hacker News
new
|
past
|
comments
|
ask
|
show
|
jobs
|
submit
login
mynameisvlad
on April 21, 2023
|
parent
|
context
|
favorite
| on:
The weird world of Windows file paths
I mean, let’s go past “Program Files” to “Program Files (x86)” which has both spaces and special characters, and which was moved from the former.
And most programs are able to handle
that
just fine.
mdaniel
on April 21, 2023
|
next
[–]
And the "cherry on top" is there's an
env-var
named `%ProgramFiles(x86)%` (aka `${env:ProgramFiles(x86)}` in PS) that points to where that directory actually lives since AFAIK it's controlled by a registry entry
Zecc
on April 22, 2023
|
prev
[–]
Sure, but that's because everyone uses SHGetFolderPath or Environment.GetFolderPath to get these paths instead of hardcoding them. Right? Right??
Guidelines
|
FAQ
|
Lists
|
API
|
Security
|
Legal
|
Apply to YC
|
Contact
Search:
And most programs are able to handle that just fine.