JAK
JAK

Reputation: 6471

Cannot navigate directory in my terminal on mac OS X. I got “No such file or directory”

I want to navigate directory in terminal. But I always got error message like this

“-bash: cd/Applications/Xcode-beta: No such file or directory”

My mac OS X is El Capitan. I am using the following command on my terminal.

Macs-Mac-mini:~ macmini1$ cd/Applications/Xcode-beta 2.app
-bash: cd/Applications/Xcode-beta: No such file or directory
Macs-Mac-mini:~ macmini1$ 

Upvotes: 3

Views: 5222

Answers (1)

Ivan
Ivan

Reputation: 2320

you want cd "/Applications/Xcode-beta 2.app" instead of cd/Applications/Xcode-beta 2.app. Note the space after cd. What you were trying to do was to execute the file in cd/Applications/ called Xcode-beta with 2.app as an argument, but obviously - it does not exist.

Also, note the quotation of Xcode-beta 2.app. Cd accepts only one argument and since there's a space in the name of this directory ( on side note - this doesn't look like a directory name, but who knows ) it will be interpreted as a separate argument to cd.

Upvotes: 7

Related Questions