LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   How to change directory? (https://www.linuxquestions.org/questions/linux-newbie-8/how-to-change-directory-181877/)

bngrhl 05-15-2004 06:38 PM

How to change directory?
 
i want to know how to change directory if i have a directory named "bng files", i used cd /bng files but it says no directory found? please help

qwijibow 05-15-2004 06:56 PM

cd Directory
means change directory into (this directory)/Directory (known as a relative directory because its relative to the directory in which you gave the command)

and cd /Directory means change directory to /Directory... as in an absolute directory at the top of the folder tree. (root)

comprookie2000 05-15-2004 06:57 PM

Try cd /usr and then ls and look could be in src try cd /src then ls and on and on ect.

slakmagik 05-16-2004 01:10 AM

If I'm understanding the problem and it's actually called 'bng files' then you need to escape it (bng\ files) or quote it ("bng files") or tab complete it (bng<tab>). And, like qwijibow said, if it's in the root directory, '/bng files' would work but, since it probably isn't, it needs to be the full path (/foo/bar/bng files) or a relative one - plain 'bng files' if its in your current, '../bng files' if it's across, etc. Because of the space, 'cd bng files' means 'change to the directory called bng' - the shell just ignores what it sees as an extra argument to the cd builtin that would mean 'change to the directory called files'.

You say it says 'no directory found' though, and it shouldn't, so maybe I'm misunderstanding. It should have said 'bash: cd: bng: No such file or directory' which tells you exactly what the problem is.

Qucho 05-16-2004 01:16 AM

Quote:

of the constant. This also simplifies modifying the program, should the value of pi change.
ROFLMAO !!!!!!!!!!!!!!!! :p

slakmagik 05-16-2004 01:20 AM

:D


All times are GMT -5. The time now is 01:39 AM.