Jump to content

“Move To” to a folder that ends with /


garblewarble
 Share

Recommended Posts

It's not entirely clear whether you're talking about a filepath or you have actually created a folder with slashes (colons) in its name. I'll assume the latter.

 

While this may indeed be a bug, the correct fix is Don't use slashes or colons in filenames.

 

You've doubtless noticed that the slash is used as the filepath separator on OS X, and as such it can't also do double duty as a valid character for a filename. They're mutually exclusive.

 

You might think you've created a file with a slash in the filename, but Finder is lying to you. Here I created two text files, "Name : with : colons.txt" in the terminal and "Name / with / slashes.txt" in Finder (a shell won't let you create a file with slashes in the name and Finder won't let you create a file with colons in the name).

 

As you can see, Finder didn't really name the file how it was told to and also lies about the filenames.
 
rrOT5ft.png

Link to comment
Share on other sites

Thanks for the explanation, thought it might have something to do with the OS. Weird how OS X allows slashes in file names then, unlike colons.

 
(In case you’re wondering why I was using slashes in the first place, I was saving webpages into folders like “alfredforum.com” (maybe also something I shouldn’t do?) and I’d then press return and copy the url of the folder if I wanted to visit that website. OS X would only automatically select e.g. “alfredforum” though, and I noticed that putting a slash at the end would cause the complete “alfredforum.com/” to be selected. But yeah, it always felt a bit hacky.)
Link to comment
Share on other sites

 

Thanks for the explanation, thought it might have something to do with the OS. Weird how OS X allows slashes in file names then, unlike colons.

 

 

 

It's holdover from the old Mac OS, which used colons as path separators. In order to maintain the appearance of compatibility, OS X silently replaces slashes in names with colons and then lies about it.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...