Are there any “unsafe” file names that can be encountered in Windows, Mac OS, Linux, etc?
For example:
New Video 2012-External RoomGED Practice SheetRgRrE-re-_d Da-
I’ve heard that even naming files with spaces, underscores, capital letters, and dashes could be potentially problematic, even though Windows doesn’t include them in their list of forbidden characters. Is this true? I vaguely recall seeing programs that don’t distinguish between uppercase and lowercase characters, and I know that HTML URLs encode unsafe ASCII characters as % (for example, spaces).
Both Unix-like (including Linux and Mac OS) and Windows should have no problem with underscores. Spaces should also generally be fine, but you occasionally find buggy code that can’t handle them.
For Windows, it’s not that capitals are problematic. It’s that Windows filesystems are case-insensitive, so in some cases when interoperating (e.g. with a git repo which is case sensitive) you can end up with problems (e.g. the repo ends up with duplicates with different capitalization).
I’m not sure about
-. One reason to avoid it is that-has special meaning for many command-line programs (e.g.rm -r). So you have to use annoying syntax like.\-r. I would also generally avoid more exotic ones like %.