Saturday, April 14, 2007

1.1 RTFM

Command Line Interface (BASH Shell)
1.1 RTFM

RTFM (Read the F@*%^#& Manual) was the first thing I learned about Unix and it's served me well on Linux. Almost every Linux command has a manual entry that's accessible through the command line. The command looks like this:
user@linux:~> man "command-name"

This will bring up the manual entry for a particular command. Which has an explanation of what the command does and the syntax of how to use it.

This is the first part of the manual entry for the "man" command.

MAN(1) Manual pager utils MAN(1)

NAME
man - an interface to the on-line reference manuals

SYNOPSIS
man [-c|-w|-tZ] [-H[browser]] [-T[device]] [-adhu7V] [-i|-I] [-m sys‐
tem[,...]] [-L locale] [-p string] [-C file] [-M path] [-P pager] [-r
prompt] [-S list] [-e extension] [[section] page ...] ...
man -l [-7] [-tZ] [-H[browser]] [-T[device]] [-p string] [-P pager] [-r
prompt] file ...
man -k [apropos options] regexp ...
man -f [whatis options] page ...

DESCRIPTION
man is the system's manual pager. Each page argument given to man is
normally the name of a program, utility or function. The manual page
associated with each of these arguments is then found and displayed. A
section, if provided, will direct man to look only in that section of
the manual. The default action is to search in all of the available
sections, following a pre-defined order and to show only the first page
Manual page man(1) line 1


As you can see the manual command reformatted the whole terminal window. So the first question is how do you quit?

To Quit press Q.
This is not intuitive at all and surprisingly missing from a lot of dead-tree resource manuals. To Interrupt press Ctrl-Z. This will halt the process but wont quit. I'm sure there is a way to restart the process but I haven't found it yet.

To access help press H.
This has a list of what all the keys do when pressed. Very useful.

To Navigate the manual entry:
To go down or up on the manual entry you can use the arrow keys or Page Up and Page Down keys.
Pressing W is the same as Page Up, pressing F as Page Down and Pressing E and Y the same as the arrow key down and up (respectively) if you have a limited keyboard.

Now you should read the manual entry for "man" and learn about the syntax of commands as explained by man.

Typing the command with the flag -? or -h will sometimes bring a different manual entry on the command.
There is also an "info" command that works the same way as the manual "man" command.

Intro: GNOME vs KDE

There are two major desktop environments in Linux: Gnome and KDE.
There is also a flame war between proponents of each.
So as a sort of disclaimer here is my take on them.

KDE is a new type of desktop environment. Very costumizable, somewhat busy and complicated. It is favored by programmers and famously the one used by Linus Trovaldis (the guy who created the Linux kernel). It is definitely new (it is not like Windows or any other OS), mature system with the better application integration. It has a steep learning curve. http://www.kde.org/whatiskde/

Gnome is sort of like a mixture of Windows XP and the Mac OSX. It is simple, but somewhat flat and while easy to costumize appearance-wise, it does not provide as much options as KDE. Because it is in-between the Windows and Mac interface, it's easy to learn. It is not as mature as KDE, but it's getting there. http://www.gnome.org/about/

I use Gnome. Mostly because I find it easier to use and it gets out of my way. Yet I use a lot of KDE applications which I believe are superior to their Gnome equivalents (like K3b for example). Like I said above the KDE is more mature and when the upcoming release of KDE4 it'll be far more advanced than Gnome. We'll see if I'll find it easier to use than its present form.

Funny thing, if you look at the website design of their respective website they are reminiscent of the Desktop Environments...

Other environments that I have used are:
XFCE which is like a simpler Gnome, Icewm which is like Win98 for Linux, and Fluxbox which is a super simple very fast window manager, but not a desktop environment.

Statement of Direction

I've been using linux for about a year now. It's a very cool system and it's come a long way since I first used it in 1995 when I was visiting a friend at MIT. I've found that there is a lack of compiled materials for linux (both online and in print) for the beginer linux user. They either shoot too low (computer newbie) or too high (compsci major). Which leaves me sort of stranded. I'm not a compsci guy or a programer but I need to know more about the system than the basic commands, and more importantly I'm not intimidated by a command line interface.
So here's where this blog comes it.
Hopefully irreverent, useful and an lonely planet guide reader's linux handbook.