LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   Open folders with spaces in the name via the CLI (https://www.linuxquestions.org/questions/linux-newbie-8/open-folders-with-spaces-in-the-name-via-the-cli-287941/)

virtualme 02-08-2005 10:29 PM

Open folders with spaces in the name via the CLI
 
How do I open folders with spaces in the name. I tried to open a folder named "New Folder" via the CLI and it would not open the folder.

I have the folder in my home folder. This is what I typed: /home/username/New Folder

When I googled, there were some articles about putting "\" where the space is, among many more different symbols. None of them worked.

How do I make this work?

PS
I could just rename the file, but I just want to know.

slakmagik 02-08-2005 10:34 PM

New\ Folder
certainly should work. So should
'New Folder'
So should
N<tab>

You didn't literally type what you said, right? You did 'cd' to it or 'ls' it or something? ;)

-- Oh, and you couldn't just rename the file without escaping it in some form or other just as you would for a cd or ls, else you'd be trying to rename two folders that don't exist - 'New' and 'Folder'.

-- Look what you got me saying. Rename two 'directories'. 'Folder' is a bad metaphor that leads to inaccurate mental models of what's going on.

virtualme 02-08-2005 10:38 PM

Yeah, sorry. I did 'cd' it and it does show up when I 'ls' also.

virtualme 02-08-2005 10:40 PM

Sweet. Thanks.
Those worked.


All times are GMT -5. The time now is 09:34 PM.