Listing 2. Code to Integrate Linux Setup with Windows
[...]
# get operating system name
setenv OS `uname`
# common setup for all OSs
source $SETUP/setup.PROXIES
# different setups for different OSs
switch($OS)
case "SunOS":
source $SETUP/setup.WORDPROC
source $SETUP/setup.WEBBROWSER
source $SETUP/SunOS/setup.OPENWIN
source $SETUP/SunOS/startup.OPENWIN
breaksw
case "Linux":
source $SETUP/setup.WEBBROWSER
source $SETUP/Linux/setup.X11
source $SETUP/Linux/startup.X11
breaksw
[...]
default:
echo "Not prepared for your OS: $OS. "
echo "You'll only get a shell."
$SHELL
endsw
[...]
Copyright © 1994 - 2019 Linux Journal. All rights reserved.