Goto Parent Directory
Say Im in /dir1/dir2/dir3/dir4
Im using Putty and each time I got to type cd /dir1/dir2/dir3 to goto dir3. Whats the Windows equivalent of cd.. ? Thanks |
It's the same thing under Linux, "cd .." will take you up a level.
|
Ah...thanks...all this time I was typing cd.. (no space in b/w cd and ..) which works in Windows.
|
You can put alias 'cd..'='cd ../' in your .bashrc file in your home directory.
|
As a brief explanation, "cd" is "change directory", "." is an abbreviation for the current directory ("pwd"), whatever that may be, and ".." is an abbreviation for the parent directory (one directory back). They're useful in many contexts besides "cd ..", e.g. things like "cd ../dir1" or "./blah.sh" to run a file not in your PATH.
|
Quote:
edit: I get what you mean, whatever the current directory may be. :) |
Quote:
|
All times are GMT -5. The time now is 06:28 AM. |