Tips Linux Explorers   All Things Linux Forum   Great Linux Links   Hometown   Email 


This has been in The Tips before, but got lost at the end part of another tip: ¨searching¨ . . Just because it´s such a handy feature of the commandline and because many members are struggling to get the commands typed correctly . . . here it is again:

The Tab key autocompletes on the commandline, you type a few characters and press the Tab key and the command or the name of the file will be completed:
Try this, "cd /u" and press tab now add an "s" and press tab, give an "h" and press tab, now we have got "cd /usr/share/" OK lets go on, type a "f" "o" "n" tab "t" tab "d" tab. < Enter > Now we are in /usr/share/fonts/ttf/decoratives. "ls" will give you a list of all the fancy ttf fonts on your system.

So next time you have to type a long command like this:

# cp /var/lib/urpmi/

You type:

# cp sy ( tab ) ( space ) /v ( tab ) li ( tab)  u ( tab ) sy ( tab )

And you will see that the full command is on your screen ( This command works only if the file "" is in your /home direcotry )

More on the Tab key and commands:

If you don´t remember exactly how a command was written, type in the first character or two and hit the tab, you will get a list of all the commands that start with that character(s).

If you wish to know what a certain command does ( ex: mkmanifest ), type:

$ whatis mkmanifest

This is what you get back to the screen :

QUOTE (Text @ Screen)
mkmanifest          (1)  - makes list of file names and their DOS 8+3 equivalent

All Linux commands and their descriptions can be found at O'Reilly


-- Aug 21 2003 ( Revised Dec 9 2005 ) --

Tips Linux Explorers   All Things Linux Forum   Great Linux Links   Hometown   Email