[UP]


Manual Reference Pages  - penv (1)

NAME

penv(1f) - [M_system:ENVIRONMENT] print all or part of environment in formats readable by various shells (LICENSE:PD)

CONTENTS

Synopsis
Description
Options
Usage
Exit Status
See Also
Author
License

SYNOPSIS

penv [variable...] [ -C| -B| -v] [ -p PREFIX] penv [ --help| --version]

DESCRIPTION

If no arguments are given, penv(1f) prints the entire environment. If one or more variable names are given, it prints the value of each one that is set, and nothing for each one that is not set.

If the -p switch is used variables beginning with that prefix will be displayed.

OPTIONS

    OUTPUT FORMAT

-C print output in a form that can be sourced into a C shell (eg. as a setenv(1) command).
-B print output in a form that can be sourced into a Bourne shell.
-v values only. Do not print variable names

    VARIABLE SELECTION

-p print only variables with the given prefix
variable(s)
  if variable names are given, print the value for each one that is set.

    INFORMATION

--help display this help and exit
--version
  output version information and exit

USAGE

Example commands:

      penv           # print entire environment
      penv -p PREFIX # print environment variables beginning with PREFIX
      penv HOME TMP LOGNAME USER # print selected variables

# csh(1)/tcsh(1) example: % penv -C > readme.csh % source readme.csh # sh(1)/bash(1)/zsh(1) ... example: $ penv -B > readme.sh $ . readme.sh # print specified variable names % penv TMP TEMPDIR TMPDIR TEMP # print variables starting with A or H % penv -p A H

EXIT STATUS

The exit status is:
0 if all variables specified were found
1 otherwise

SEE ALSO

env(1), printenv(1)

AUTHOR

John S. Urban

LICENSE

Public Domain


penv (1) March 11, 2021
Generated by manServer 1.08 from b4588e37-d617-48c0-9897-7188486456ad using man macros.