UNIX Guide, for beginners and Mac OS X users
You are here: SillyDog701 > UNIX Guide >SillyDog701 > UNIX Guide > (index) supportSupport - ask in our friendly forums.

Examples of changing environment variables: Bourne shell

To change to using another printer for the current login session:

   PRINTER=ps2

Whenever the user prints a file, the output will be sent to the printer ps2.

To change to using another editor for the current login session and inform (export) this value to other programs which use it:

   EDITOR=vi
   export EDITOR

This changes the user's default editor to vi and exports this value to other programs - such as electronic mail - which make use of it.

To change to using another pager for viewing files the user adds the following lines to their .profile file.

   PAGER=less;export PAGER

To make this change take immediate effect enter the command:

   . .profile

This causes the .profile file to be read, setting the variables to their new values.


[Home]UNIX Guide home | [Search]search | index
Page URL: http://sillydog.org/unix/
[SillyDog701] [Netscape] [MozInfo701] [MacCentre701] [UNIX Guide] [AntTunes701][Forums] [Search] [Change Log] [Feedback] [About Us] [Sitemap]
This UNIX Guide maintained by SillyDog701, portion of this Guide is based on UNIXhelp. UNIXhelp is copyright University of Edinburgh. This page was last modified on 14 March, 2006
Netscape NOW!Made on a Mac
support MozInfo701 and SillyDog701