Skip to Content
Running Linux, 5th Edition
book

Running Linux, 5th Edition

by Matthias Kalle Dalheimer, Matt Welsh
December 2005
Beginner
974 pages
31h 50m
English
O'Reilly Media, Inc.
Content preview from Running Linux, 5th Edition

Startup Files

Configuration is a strong element of Unix. This probably stems from two traits commonly found in hackers: they want total control over their environment, and they strive to minimize the number of keystrokes and other hand movements they have to perform. So all the major utilities on Unix—editors, mailers, debuggers, X Window System clients—provide files that let you override their default behaviors in a bewildering number of ways. Many of these files have names ending in rc, which means resource configuration.

Startup files are usually in your home directory. Their names begin with a period, which keeps the ls command from displaying them under normal circumstances. None of the files is required; all the affected programs are smart enough to use defaults when the file does not exist. But everyone finds it useful to have the startup files . Here are some common ones:

.bashrc

For the bash shell. The file is a shell script, which means it can contain commands and other programming constructs. Here's a very short startup file that might have been placed in your home directory by the tool that created your account:

PS1='\u$' # The prompt contains the user's login name. HISTSIZE=50 # Save 50 commands for when the user presses the up arrow. # All the directories to search for commands. PATH=/usr/local/bin:/usr/bin:/bin:/usr/bin/X11 # To prevent the user from accidentally ending a login session, # disable Ctrl-D as a way to exit. IGNOREEOF=1 stty erase "^H" # Make sure the backspace ...
Become an O’Reilly member and get unlimited access to this title plus top books and audiobooks from O’Reilly and nearly 200 top publishers, thousands of courses curated by job role, 150+ live events each month,
and much more.
Start your free trial

You might also like

Running Linux, Third Edition

Running Linux, Third Edition

Matthias Kalle Dalheimer, Lar Kaufman, Matt Welsh
Linux in a Nutshell, 6th Edition

Linux in a Nutshell, 6th Edition

Ellen Siever, Stephen Figgins, Robert Love, Arnold Robbins
Linux in Action

Linux in Action

David Clinton
Linux Under the Hood

Linux Under the Hood

Sander van Vugt

Publisher Resources

ISBN: 0596007604Errata Page