Changeset View
Changeset View
Standalone View
Standalone View
usr.bin/env/env.1
Show All 25 Lines | |||||
.\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY | .\" LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY | ||||
.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF | .\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF | ||||
.\" SUCH DAMAGE. | .\" SUCH DAMAGE. | ||||
.\" | .\" | ||||
.\" From @(#)printenv.1 8.1 (Berkeley) 6/6/93 | .\" From @(#)printenv.1 8.1 (Berkeley) 6/6/93 | ||||
.\" From FreeBSD: src/usr.bin/printenv/printenv.1,v 1.17 2002/11/26 17:33:35 ru Exp | .\" From FreeBSD: src/usr.bin/printenv/printenv.1,v 1.17 2002/11/26 17:33:35 ru Exp | ||||
.\" $FreeBSD$ | .\" $FreeBSD$ | ||||
.\" | .\" | ||||
.Dd April 17, 2008 | .Dd November 3, 2019 | ||||
imp: date :)
| |||||
.Dt ENV 1 | .Dt ENV 1 | ||||
.Os | .Os | ||||
.Sh NAME | .Sh NAME | ||||
.Nm env | .Nm env | ||||
.Nd set environment and execute command, or print environment | .Nd set environment and execute command, or print environment | ||||
.Sh SYNOPSIS | .Sh SYNOPSIS | ||||
.Nm | .Nm | ||||
.Op Fl iv | .Op Fl 0iv | ||||
.Op Fl P Ar altpath | .Op Fl P Ar altpath | ||||
.Op Fl S Ar string | .Op Fl S Ar string | ||||
.Op Fl u Ar name | .Op Fl u Ar name | ||||
.Op Ar name Ns = Ns Ar value ... | .Op Ar name Ns = Ns Ar value ... | ||||
.Op Ar utility Op Ar argument ... | .Op Ar utility Op Ar argument ... | ||||
.Sh DESCRIPTION | .Sh DESCRIPTION | ||||
The | The | ||||
.Nm | .Nm | ||||
utility executes another | utility executes another | ||||
.Ar utility | .Ar utility | ||||
after modifying the environment as | after modifying the environment as | ||||
specified on the command line. | specified on the command line. | ||||
Each | Each | ||||
.Ar name Ns = Ns Ar value | .Ar name Ns = Ns Ar value | ||||
option specifies the setting of an environment variable, | option specifies the setting of an environment variable, | ||||
.Ar name , | .Ar name , | ||||
with a value of | with a value of | ||||
.Ar value . | .Ar value . | ||||
All such environment variables are set before the | All such environment variables are set before the | ||||
.Ar utility | .Ar utility | ||||
is executed. | is executed. | ||||
.Pp | .Pp | ||||
The options are as follows: | The options are as follows: | ||||
.Bl -tag -width indent | .Bl -tag -width indent | ||||
.It Fl 0 | |||||
End each output line with NUL, not newline. | |||||
.It Fl i | .It Fl i | ||||
Execute the | Execute the | ||||
.Ar utility | .Ar utility | ||||
with only those environment variables specified by | with only those environment variables specified by | ||||
.Ar name Ns = Ns Ar value | .Ar name Ns = Ns Ar value | ||||
options. | options. | ||||
The environment inherited | The environment inherited | ||||
by | by | ||||
▲ Show 20 Lines • Show All 52 Lines • ▼ Show 20 Lines | |||||
options. | options. | ||||
.Pp | .Pp | ||||
If no | If no | ||||
.Ar utility | .Ar utility | ||||
is specified, | is specified, | ||||
.Nm | .Nm | ||||
prints out the names and values | prints out the names and values | ||||
of the variables in the environment, with one name/value pair per line. | of the variables in the environment, with one name/value pair per line. | ||||
If | |||||
.Fl 0 | |||||
is supplied, | |||||
.Ar utility | |||||
is ignored and the variables are separated by NUL instead of lines. | |||||
.\" | .\" | ||||
.Ss Details of Fl S \&Ss (split-string) processing | .Ss Details of Fl S \&Ss (split-string) processing | ||||
The processing of the | The processing of the | ||||
.Fl S | .Fl S | ||||
option will split the given | option will split the given | ||||
.Ar string | .Ar string | ||||
into separate arguments based on any space or <tab> characters found in the | into separate arguments based on any space or <tab> characters found in the | ||||
.Ar string . | .Ar string . | ||||
▲ Show 20 Lines • Show All 340 Lines • Show Last 20 Lines |
date :)