Gentoo Wiki


This article is part of the Tips & Tricks series.
Terminals / Shells Network X Window System Portage System Filesystems Kernel Other



Here are some basic commands for the uninitiated. Since you've decided to jump way into the deep end with Gentoo, here's a little life preserver:

Uber Basic

lslist files (You can create useful aliases in your .bash_profile for things like l='ls -A', ll='ls -l', dir='ls -d'. I would also highly suggest the alias ls='ls --color=auto' for those terminals where color is an option.)
cpcopy files (the -r flag copies directories recursively; !!beware!! as cp overwrites any files you already have there -- use cp -i to interactively query whether you want to destroy any named files)
mvmove files (same thing as 'cp', except that you have the useful option '-p' to create a directory and all of its parent directories, should they not already exist)
rmremove files (!!again, beware!!, use '-i' to make sure you don't remove something you want -- once it's gone, it's gone!
catprint file to screen (perhaps somewhat less useful than 'less' for looking at a file, but it can be useful when piping between different commands like 'sort' or 'uniq')
findfind a file on the filesystem (read the manpage on how to use this utility - it ain't simple; instead, you might try to use a combination of 'locate XXX' piped into 'grep YYY' to find what you're looking for; 'find' is rather finicky)
lpline print a file (this, of course, assumes you have cupsd or some other printing system running in the background)

Lesser Known


A Very Consise Bash Quick Refrence (pdf)

Retrieved from ""

Last modified: Sun, 06 Aug 2006 01:20:00 +0000 Hits: 3,011