source: trunk/minix/man/man7/environ.7@ 15

Last change on this file since 15 was 9, checked in by Mattia Monga, 14 years ago

Minix 3.1.2a

File size: 2.6 KB
Line 
1.\" Copyright (c) 1983 Regents of the University of California.
2.\" All rights reserved. The Berkeley software License Agreement
3.\" specifies the terms and conditions for redistribution.
4.\"
5.\" @(#)environ.7 6.1 (Berkeley) 5/20/85
6.\"
7.TH ENVIRON 7 "May 20, 1985"
8.UC 5
9.SH NAME
10environ \- user environment
11.SH SYNOPSIS
12.B "extern char *const *environ;"
13.SH DESCRIPTION
14An array of strings called the `environment' is made available by
15.BR execve (2)
16when a process begins. By convention these strings have the form
17.RI ` name = value '.
18The following names are used by various commands:
19.TP "\w'TERMCAP 'u"
20.B PATH
21The sequence of directory prefixes that
22.BR sh ,
23.BR time ,
24.BR nice (1),
25etc., apply in searching for a file known by an incomplete path name.
26The prefixes are separated by `:'.
27Login shells set
28.BR PATH=:/bin:/usr/bin .
29Note that the empty space between the `=' and the `:' indicates the current
30directory. Security aware people move the extra `:' to the end of their
31path or omit it.
32.TP
33.B HOME
34A user's login directory, set by
35.BR login (1)
36from the password file
37.BR passwd (5).
38.TP
39.B TERM
40The kind of terminal for which output is to be prepared.
41This information is used by programs that wish to exploit special
42terminal capabilities, a screen oriented text editor for instance.
43The terminal type is set by
44.BR login (1)
45from the tty database
46.BR ttytab (5).
47.TP
48.B SHELL
49The file name of the users login shell, set by
50.BR login (1)
51from the password file
52.BR passwd (5).
53.TP
54.B TERMCAP
55The string describing the terminal in TERM, or the name of the termcap file,
56see
57.BR termcap (5),
58.BR termcap (3).
59.TP
60.B EXINIT
61A startup list of commands read by
62.BR elvis (1).
63.TP
64.B USER
65The login name of the user, set by
66.BR login (1)
67from the password file
68.BR passwd (5).
69.TP
70.B LOGNAME
71Set to the same value as
72.BR USER .
73BSD derived systems have
74.BR USER ,
75System V has
76.BR LOGNAME ,
77so modern systems have both to avoid problems.
78.TP
79.PP
80Further names may be placed in the environment by the
81.B export
82command and
83.RI ` name = value '
84arguments in
85.BR sh (1).
86Arguments may also be placed in their environment by
87programs if they use
88.BR putenv (3).
89Or in the environment of another program by building a new environment
90for one of the exec functions that accepts an environment list, like
91.BR execle (2)
92or
93.BR execve (2).
94It is unwise to conflict with certain
95.BR sh (1)
96variables that are frequently set and/or exported by `.profile' files:
97.BR MAIL ,
98.BR PS1 ,
99.BR PS2 ,
100.BR IFS .
101.SH SEE ALSO
102.BR elvis (1),
103.BR login (1),
104.BR sh (1),
105.BR execl (3),
106.BR execve (2),
107.BR system (3),
108.BR termcap (3),
109.BR termcap (5),
110.BR passwd (5),
111.BR ttytab (5).
Note: See TracBrowser for help on using the repository browser.