Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

Windows Explorer (the one in Win8.1, at least) won't allow creation of files with a space at the beginning or end of a name, but it's definitely allowed in the filesystem. For example, from a command prompt, this works:

  echo hi > " hello.txt"
Explorer can see this file and perform operations on it, but if you try to rename it to a name with leading or trailing spaces, they get trimmed.

I have used '~' to cause files to sort at the top - this seems to be some oddity of the sorting order that Explorer uses, since ~ would sort at the end in ASCIIbetical order - but at least it's an allowed character at the beginning of a name in Explorer, unlike space.



If we're picking characters to use to cause files to sort at the top, I'll stick with '!'




Consider applying for YC's Fall 2026 batch! Applications are open till July 27.

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: