Friday, July 18, 2008

How to move to a folder fast in the terminal

Assuming that the folder is placed in home directory you type

cd /home/the_name_of_the_folder_you_want_opened

You can work around the space in the folder name by using quotes:

cd "saya lagi"

- Or you can "escape" any special character by putting a \ before it:

cd saya\ lagi

- Or just make use of the autocomplete feature using the tab key:

Type: cd sa and then just press the tab key so that linux can automatically complete the line for you. This only works if there are no other folders that begin with the letters "sa", else you should try "cd say" and tab or "cd saya" and tab, etc. If you press tab twice you'll get a list of possible folder names.

You can also drag a long named folder in the terminal and type cd before the name; use Ctrl+a to move the cursor to the beginning of the line.

Lastly, in case you use regular ubuntu (Gnome/nautilus) you can install the package nautilus-open-terminal, that will allow you to right-click a folder and start a terminal from there.

No comments:

Blog Archive

About Me

Exclusion of liability Regarding StillStupid: The use you make of the guides, tips and downloads that you listed on this web site or on another website to which I refer is entirely at your own risk. In no way can I be held liable for damage or consequential damages of any kind, which occurs as a result of that use.