This script puts in the .profile should works.
I use it to export automatically DISPLAY environment when i do telnet to my
Netview machine.
#This is the .profile of my AIX 4.3.2 system.
Host=`who am i |awk '{print $6}'|sed 's/(//'|sed 's/)//'`
if [[ $Host = `hostname -s` ]]
then
export DISPLAY=:0.0
else
export DISPLAY=$Host:0.0
fi
Pagano Giuseppe
I/T Specialist
IBM Italia SpA - Global Services/PSS Tivoli Service Unit Lombardia Large
Circonvallazione Idroscalo - 20090 Segrate (MI)
E-mail: giuseppe_pagano@it.ibm.com
Does anyone know of a way to set the DISPLAY environment variable based on
the system name you are coming in from? I tried a shell script but it
doesn't pass the variable back to the parent process. TIA
Steve Stamper
Grand Rapids, MI
|