ticks! :) `/bin/hostname` _______________ Jonathan Furrer jonny@jofu.com http://www.jofu.com/ On Mon, 30 Oct 2000, Don Harrop wrote: > Ok, here's the first HP-UX question. I want to setup the HOSTNAME var to > function like it does under Linux. If I set HOSTNAME='/bin/hostname' and > echo $HOSTNAME I get '/bin/hostname' printed back, not the hostname of the > machine.. Any ideas? > > Don > > > ________________________________________________ > See http://PLUG.phoenix.az.us/navigator-mail.shtml if your mail doesn't post to the list quickly and you use Netscape to write mail. > > Plug-discuss mailing list - Plug-discuss@lists.PLUG.phoenix.az.us > http://lists.PLUG.phoenix.az.us/mailman/listinfo/plug-discuss > From Don Harrop Mon Oct 30 18:47:04 2000 From: Don Harrop (Don Harrop) Date: Mon, 30 Oct 2000 11:47:04 -0700 (MST) Subject: Environment vars calling programs In-Reply-To: <70E6E8BEF851D3119B080000F805EA8201575A20@ACA_EXCHANGE> Message-ID: Damn, I hate syntax! ;-) That's what I get for playing with Linux boxes that have always set stuff up like that for me.. I've got a couple other questions that might be pretty easy too.. Basically what I want to do is create a prompt that displays the username@hostname:pathname like you get in most Linux installs. With that last tid-bit I can set the prompt to print everything I want until I su. The username doesn't follow the user. I'm setting USER=`whoami` and using $USER in PS1 to get the username. I've also used `whoami` directly in the PS1 var. No luck. Is that because the su program on HP-UX isn't designed to update any env vars? I'm setting all this up in the global config files so whoever I log in as gets this setup but as soon as you su to anyone else it seems like it looses the environment variable info. Also when telneting in I have to use ctrl H to backspace. I've set ERASE='^H' and that doesn't seem to help. Do I have to use the escape code? The environment is HP-UX 10.20 and I'm running a standard POSIX shell. On Mon, 30 Oct 2000, Jeffrey Pyne wrote: > Try using backticks instead of single quotes (i.e. > HOSTNAME=`/bin/hostname`). > > -----Original Message----- > From: Don Harrop [mailto:don@nis4u.com] > Sent: Monday, October 30, 2000 10:28 AM > To: plug-discuss@lists.PLUG.phoenix.az.us > Subject: Environment vars calling programs > > > Ok, here's the first HP-UX question. I want to setup the HOSTNAME var to > function like it does under Linux. If I set HOSTNAME='/bin/hostname' and > echo $HOSTNAME I get '/bin/hostname' printed back, not the hostname of the > machine.. Any ideas? > > Don > > > ________________________________________________ > See http://PLUG.phoenix.az.us/navigator-mail.shtml if your mail doesn't post > to the list quickly and you use Netscape to write mail. > > Plug-discuss mailing list - Plug-discuss@lists.PLUG.phoenix.az.us > http://lists.PLUG.phoenix.az.us/mailman/listinfo/plug-discuss > > ________________________________________________ > See http://PLUG.phoenix.az.us/navigator-mail.shtml if your mail doesn't post to the list quickly and you use Netscape to write mail. > > Plug-discuss mailing list - Plug-discuss@lists.PLUG.phoenix.az.us > http://lists.PLUG.phoenix.az.us/mailman/listinfo/plug-discuss > From Don Harrop Mon Oct 30 19:25:55 2000 From: Don Harrop (Don Harrop) Date: Mon, 30 Oct 2000 12:25:55 -0700 (MST) Subject: HP-UX environment stuff Message-ID: Nevermind about the ctrl H thing. I just figured it out.. It was just a setting in the telnet program I was using.. Don