And "path component" is not an arbitrary string either - e.g. appending a path component to the path should first require converting/parsing the string into the path component, and only if that's successful appending it to the path.
I'm “still afraid to use spaces in file names” years old
131–140 of 817 posts
Re: I'm “still afraid to use spaces in file names” years old
#132Re: I'm “still afraid to use spaces in file names” years old
#133If I'm going to use the file in the command line, I won't use spaces, since I don't know what sick bug I might encounter.
Re: I'm “still afraid to use spaces in file names” years old
#134I work on a complex desktop application, and it's been astounding the number of bugs that have appeared over the years triggered by spaces and other unusual characters in file names. If you do anything with subprocesses or path processing, it's absurdly easy to hit in a thousand different ways, over and over again. Pro tip: rename your development directory (or even better: the workspace path in CI) to put a space an…
thisismyconfig.txt vs this is my config.txt or this_is_my_config.txt
...i've forced myself to stop using spaces, character, and even cap. They are all constructs that provide minimal value for the extra complexity.
Re: I'm “still afraid to use spaces in file names” years old
#135Earlier quoted context omitted.
Seems like MS had the same idea according to an answer in the link: > Microsoft intentionally made programs install to C:\Program Files on Windows 95+ to force programmers to deal with spaces in filenames.
And yet they introduced C:\ProgramData in later versions.
one occurrence is enough to make devs care about it
Re: I'm “still afraid to use spaces in file names” years old
#136Earlier quoted context omitted.
Seems like MS had the same idea according to an answer in the link: > Microsoft intentionally made programs install to C:\Program Files on Windows 95+ to force programmers to deal with spaces in filenames.
And yet they introduced C:\ProgramData in later versions.
Re: I'm “still afraid to use spaces in file names” years old
#137Re: I'm “still afraid to use spaces in file names” years old
#138Still way too many libraries and programs can't handle spaces in filenames. And shells and other programs still have problems with perfectly legal characters in filenames too, like '!' or ':'.
I also love when you're using bash and you have a file with ! in the name, and you accidentally fail to correctly backslash it, you not only get "bash: !rest_of_filename: event not found", but it also fails to add that command line to the history, so you can't just hit up and fix it. You have to actually go to the mouse and copy and paste.
Re: I'm “still afraid to use spaces in file names” years old
#139I am also that age, and kebab-case is the best case for filenames. 2021-01-01-some-important-document.pdf gives me the warm fuzzies. On the off chance that some more differentiation is needed, throw in an underscore and a whole new world opens up
Re: I'm “still afraid to use spaces in file names” years old
#140I am also that age, and kebab-case is the best case for filenames. 2021-01-01-some-important-document.pdf gives me the warm fuzzies. On the off chance that some more differentiation is needed, throw in an underscore and a whole new world opens up
I hadn't heard that before and I love it.