Web design templates - 208 CHAPTER 13 INTRODUCING THE BASH SHELL
208 CHAPTER 13 INTRODUCING THE BASH SHELL user, as opposed to the root user. However, unlike most other Linux distributions, Ubuntu doesn t use the root account during day-to-day operations, so this is a moot point. Finally, there is a cursor, and this is where you can start typing commands! Note If you were to log in as root, a hash (#) would appear instead of the dollar prompt. This is important to remember because often in magazines and some computer manuals the use of the hash symbol before a command indicates that it should be run as root. In addition, if you use the rescue function of the install CD, you ll be running as root, and a hash will appear at the prompt. See Chapter 14 for more information about the root user. Running Programs When we refer to commands at the shell, we re actually talking about small programs. When you type a command to list a directory, for example, you re actually starting a small program that will do that job. Seen in this light, the shell s main function is to simply let you run programs either those that are built into the shell, such as ones that let you manipulate files, or other, more complicated programs that you ve installed yourself. The shell is clever enough to know where your programs are likely to be stored. This information was given to it when you first installed Ubuntu and is stored in a system variable. Note A variable is the method Linux uses to remember things like names, directory paths, or other data. There are many system variables that are vital for the running of Ubuntu. The information about where your programs are stored, and therefore where Ubuntu should look for commands you type in, as well as any programs you might want to run, is stored in the PATH variable. You can take a look at what s currently stored there by typing the following: echo $PATH Don t forget that the difference between uppercase and lowercase letters matters to Ubuntu, unlike with Windows and DOS. The echocommand merely tells the shell to print something on screen. In this case, you re telling it to echo the PATH variable onto your screen. On my test PC, this returned the following information: /usr/local/bin:/usr/local/sbin:/sbin:/usr/sbin:/bin:/usr/bin:/usr/bin/X11:/usr/games Several directories are in this list, each separated by a colon.