Find it
Custom Search

Monday, October 10, 2005

Further Discussion on the cd Command



A few more notes regarding the cd command.

There is an easier way of changing directories.

If you are familiar with the directory hierarchy of your Linux installation, you can type cd plus the absolute path of your destination directory.

For example:

1. Type:
$ cd /usr/bin

2. Then type:

$ pwd

to verify.

If you want to go back to your home directory, in my case it's, /home/anthony,
simply type:

$ cd /home/anthony

Then type:

$ pwd

And you will see that you are back to your original directory.

There is a shorter way of doing this of course.

Simply type:

$ cd

The cd command without any argument always brings you back to your default directory.

On the next post we will learn about moving and renaming files.

No comments: