Free Hosting Online for WorkStations

< Previous | Contents | Next >

Some Interesting Variables

The environment contains quite a few variables, and though the environment will differ from the one presented here, we will likely see the following variables in our environ- ment:


Table 11-1: Environment Variables


Variable Contents

Variable Contents

DISPLAY The name of your display if you are running a graphical environment. Usually this is “:0”, meaning the first display generated by the X server.


EDITOR The name of the program to be used for text editing.


SHELL The name of your shell program.


HOME The pathname of your home directory.


LANG Defines the character set and collation order of your language.


OLD_PWD The previous working directory.


PAGER The name of the program to be used for paging output. This is often set to /usr/bin/less.


PATH A colon-separated list of directories that are searched when you enter the name of a executable program.


PS1 Prompt String 1. This defines the contents of the shell prompt. As we will later see, this can be extensively customized.



PWD The current working directory.


TERM The name of your terminal type. Unix-like systems support many terminal protocols; this variable sets the protocol to be used with your terminal emulator.


TZ Specifies your timezone. Most Unix-like systems maintain the computer’s internal clock in Coordinated Universal Time (UTC) and then displays the local time by applying an offset specified by this variable.


USER Your username.



Don't worry if some of these values are missing. They vary by distribution.


Top OS Cloud Computing at OnWorks: