trivial pathname changes
[unix-history] / usr / src / usr.bin / printenv / printenv.1
CommitLineData
b5dc1377 1.\" Copyright (c) 1980, 1990 The Regents of the University of California.
4863c0b1 2.\" All rights reserved.
ae8545ab 3.\"
b5dc1377 4.\" %sccs.include.redist.man%
4863c0b1 5.\"
b5dc1377 6.\" @(#)printenv.1 6.3 (Berkeley) %G%
ae8545ab 7.\"
b5dc1377
CL
8.Dd
9.Dt PRINTENV 1
ae8545ab 10.UC
b5dc1377
CL
11.Sh NAME
12.Nm printenv
13.Nd print out the environment
14.Nm env
15.Nd set and print out the environment
16.Sh SYNOPSIS
17.Nm printenv
18.Op Ar name
19.Nm env
20.Op Fl
21.Op Ar name=value \&...
22.Op Ar command
23.Sh DESCRIPTION
24.Nm Printenv
4863c0b1 25prints out the names and values of the variables in the environment,
b5dc1377
CL
26with one name/value pair per line. If
27.Ar name
28is specified, only
4863c0b1 29its value is printed.
b5dc1377 30.Pp
ae8545ab 31If a
b5dc1377 32.Ar name
ae8545ab 33is specified and it is not defined in the environment,
b5dc1377 34.Nm printenv
ae8545ab 35returns exit status 1, else it returns status 0.
b5dc1377
CL
36.Pp
37.Nm Env
38executes
39.Ar command
40after modifying the environment as
41specified on the command line. The option
42.Ar name=value
43specifies
44an environmental variable,
45.Ar name ,
46with a value of
47.Ar value .
48The option
49.Fl
50causes
51.Nm env
52to completely ignore the environment
4863c0b1 53it inherits.
b5dc1377
CL
54.Pp
55If no command is specified,
56.Nm env
57prints out the names and values
4863c0b1 58of the variables in the environment, with one name/value pair per line.
b5dc1377
CL
59.Sh SEE ALSO
60.Xr csh 1 ,
61.Xr sh 1 ,
62.Xr execvp 3 ,
63.Xr environ 7
64.Sh HISTORY
65.Nm Printenv
66appeared in 3 BSD.
67.Sh BUGS
68.Nm Env
69doesn't handle commands with equal (``='') signs in their
4863c0b1 70names, for obvious reasons.