Usenet comp.unix.osf.misc (1992-2004)
 help / color / mirror / Atom feed
From: "Hans Peter Kain" <hanspeter.kain@eis.at.telegyr.com>
Subject: Re: Shell prompt of root
Date: 1999/04/22	[thread overview]
Message-ID: <371ee501.0@server02.bnet.at> (raw)
In-Reply-To: 7fk2bo$egd@ustsu10.ust.hk

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #1: Type: text/plain, Size: 707 bytes --]

To change the shell prompt of root user in a bourne shell simply add the
following  two entries in the $HOME/.profile - File of your root user:

PS1="`hostname`#"
export PS1

Thats all.

PS1 is an predefined shell variable that defines the primary system prompt.
You can also define a secondary system prompt (=PS2) which is used if a
command extends over more than one line.

It is very important to use the character ` not � or ' because all whats
between two � is interpreted as a command.

Regards

Hans Peter.


Chan Kin Man schrieb in Nachricht <7fk2bo$egd@ustsu10.ust.hk>...
>Dears,
>
>How can I change the prompt of bourne shell (root user) from
>'#' to 'hostname#' ?
>
>Thanks.
>
>MAN
>~~~





      reply	other threads:[~1999-04-22  4:00 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
1999-04-21  4:00 Shell prompt of root Chan Kin Man
1999-04-22  4:00 ` Hans Peter Kain [this message]
read-only archive

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox