svenv(1) — USER COMMANDS
NAME
svenv − export SunView environment
SYNOPSIS
svenv [ −display dpy ] [ −warn ] −env [ −csh ]
svenv [ −display dpy ] [ −warn ] −exec command [ args ... ]
DESCRIPTION
The svenv program contacts the X11/NeWS server and retrieves information necessary for running SunView programs. svenv can fork a program with this information in the environment, or it can issue commands so that a shell script can set up its environment with this information.
With the -env option, svenv will generate shell commands to set the SunView environment variables. By default, svenv will generate commands suitable for sh(1). With the −csh option, svenv will generate commands suitable for csh(1). Invoking svenv this way is useful for setting up the environment of a shell script (such as .xinitrc) so that several programs may be run with under the same environment. This technique can be used as follows:
# get the SunView environment
eval ‘svenv -env‘
# run some SunView programs
/usr/bin/cmdtool &
/usr/bin/textedit -Wi &
With the -exec option, svenv will export the SunView information and then fork the program named by command, passing along any args also given. If the system is configured with multiple OpenWindows screens, svenv must be invoked once for each screen. Refer to openwin(1) for more information.
DEVICE SUPPORT
Sunview binaries may not be run on all devices supported by OpenWindows. For a list of devices which do not support Sunview binaries, refer to the OpenWindows Programming Guide.
svenv is a null operation for these devices; no Sunview environment is exported to client programs.
OPTIONS
−csh
When used with −env, output environment-setting commands suitable for csh(1) instead of sh(1).
−display
Specify the X11 display to which to connect.
−env
Issue Bourne shell command to set up the environment.
−exec command args ...
Set up the environment and fork command, passing along args.
−warn
If Sunview binaries may not be run on the specified screen, svenv, will not generate a warning message unless this option is given.
ENVIRONMENT
svenv handles the following environment variables:
WINDOW_PARENT
WINDOW_TTYPARMS
WMGR_ENV_PLACEHOLDER
svenv does not look at the SHELL environment variable to determine the syntax of the environment-setting commands. The reason is that svenv is typically executed from the .xinitrc file, which is always run by sh(1). If svenv based its output on the SHELL environment variable, an invocation of svenv within a .xinitrc file might issue commands with the wrong shell syntax.
SEE ALSO
OpenWindows Programming Guide
Sun Release 4.1 — Last change: 7 December 1989