Main index

Introducing UNIX and Linux


Processes and devices

Overview
Processes
      Process status
      Foreground and background
      Process control
      Signals
Environment
      Environment variables
      Global and local variables
      Executable scripts
Program control
      Job control
      Command history list
      Running a job at a specific time
      Running programs periodically
      Big programs
      Timing a program
      Running programs in order
Quotes and escapes
Devices
Backquotes
Summary
Exercises

Answer to chapter 6 question 5

This is an exercise in knowing the names of the environment variables which store the relevant information.

echo "Your username is $LOGNAME"
echo "Home directory is $HOME"
echo "You are using a terminal which is a $TERM"
echo "The default lineprinter is $PRINTER"

Copyright © 2002 Mike Joy, Stephen Jarvis and Michael Luck