Sponsored Content
Full Discussion: How to change prompt
Top Forums UNIX for Dummies Questions & Answers How to change prompt Post 302188206 by era on Wednesday 23rd of April 2008 01:51:28 AM
Old 04-23-2008
Depends somewhat on the shell. In Bourne-compatible shells, the variable PS1 determines the primary prompt. There's also PS2 and PS4 (sic) for secondary and tertiary prompts. See the manual page for your shell for more information.

Code:
PS1='root@server # '

The secondary prompt is what you see when you leave a quote open and continue on the next line. It is usually set to "> " by default.

Code:
# echo "hello
> world"

If your shell is csh or tcsh, those are not Bourne-compatible (but have a manual page, too).
 

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

script to change shell and prompt

I want to write a shell script which will change the current shell (say from csh to bsh) and my Prompt (say my name) as desired.pls help (1 Reply)
Discussion started by: SHYAM
1 Replies

2. Solaris

How to change the system prompt and BG of terminal?

Hi all, I was wondering how to change the PS1 to my liking? I tried changing it using PS1='my choice' it worked but the subsequent terminals i open will not have it as the default PS1 ,how do i change it? also i am running as super user, and i need to exec bash, to get the bash environment...... (4 Replies)
Discussion started by: wrapster
4 Replies

3. AIX

how to change the font size of shell in $ prompt

Can any help me to change the default font type and its size.. To clear more about my question.. Once i login to my unix domain... the font it displaying is of small size... all my shell commands i am executing in $ prompt also carries the same style(ls, date and echo...) i searched whole... (2 Replies)
Discussion started by: tsjpraveen
2 Replies

4. UNIX for Dummies Questions & Answers

Change root prompt (Solaris)

Hello all. I was wondering if there is a way to change the root prompt. I am using Solaris 10 and would like to have the root prompt display the current directory along with 'SU' to indicate root status. What I have tried so far: /etc/passwd changed the root shell to korn with... (10 Replies)
Discussion started by: RobertSubnet
10 Replies

5. UNIX for Dummies Questions & Answers

Where to change the UNIX password prompt?

Hi guys, I got these 3 servers: a, b and c which I ssh from a to b/c. a:$ ssh userid@b Password: a:$ ssh userid@c userid@c's password: Notice that the password prompt is different (highlighted in bold) on both servers even though their SUN Solaris version the same, OpenSSH version... (0 Replies)
Discussion started by: DrivesMeCrazy
0 Replies

6. Shell Programming and Scripting

How can i change my bash prompt ?

It looks like, user@hostname:/auto/home3/user$ Desired, user@hostname$ I added following line in .bashrc, but still its same. export PS1=" $ " Please help me :confused: (13 Replies)
Discussion started by: admax
13 Replies

7. UNIX for Advanced & Expert Users

Change password prompt format

Hello, I installed Kerberos on Red Hat. My testing tool checks for the prompt when user log-in. Unfortunately I don't have access to that testing tool so I have to fix somehow the prompt. My testing tool expects this format: login: XYZ Password: When I installed Kerberos I have this format:... (1 Reply)
Discussion started by: susja
1 Replies

8. Red Hat

How to change password prompt for Kerberos?

Hello, I installed Kerberos on Red Hat. My testing tool checks for the prompt when user log-in. Unfortunately I don't have access to that testing tool so I have to fix somehow the prompt. My testing tool expects this format: login: XYZ Password: When I installed Kerberos I have this format:... (1 Reply)
Discussion started by: susja
1 Replies

9. Shell Programming and Scripting

how to change unix cmd display prompt?

I am new to to unix and I want to make my own basic shell. What is the code I can use to change the unix cmd console display? For example my unix display prompt says MyCompterName~, I want it to say WhatEverMan~ (3 Replies)
Discussion started by: megaearth77
3 Replies

10. UNIX for Dummies Questions & Answers

How to Change the % prompt to - prompt in UNIX?

how to Change the % prompt to - prompt in unix :wall: ---------- Post updated at 07:40 AM ---------- Previous update was at 07:38 AM ---------- How To display the last modification time of any file in unix ---------- Post updated at 07:40 AM ---------- Previous update was at 07:40 AM... (2 Replies)
Discussion started by: manjiri sawant
2 Replies
XTELL(1)						      General Commands Manual							  XTELL(1)

NAME
xtell - sends a message to another computer running xtelld SYNOPSIS
xtell [-v] [user[:tty][@host[:port]]] [message] write user [tty] DESCRIPTION
How to use it: suppose you want to send a message to user gubas on computer trener.fsport.uniba.sk Just type: prompt:~% xtell gubas@trener.fsport.uniba.sk Hi To send multiple lines long message to user 7tokarova at computer pascal.fmph.uniba.sk, type prompt:~% xtell 7tokarova@pascal.fmph.uniba.sk Hi How are you today Please answer ^D in this case, finish sending messages with EOF (CTRL D) If you want to send message to user holik on local computer, you can do it either by typing: prompt:~% xtell holik@localhost Hi or simply: prompt:~% xtell holik Hi To send message to certain tty, append the tty to username, separated by colon: prompt:~% xtell stanys:ttyp2@reaktor.ip.fmph.uniba.sk 'Sveikas Tomai' will send message 'Sveikas Tomai' to user stanys on ttyp2 at computer reaktor.ip.fmph.uniba.sk To specify other port than the default 4224, append the port to computer name, separated by colon: prompt:~% xtell bosa@radon.dnp.fmph.uniba.sk:4000 'Ahoj' assumes the xtell daemon runs at computer radon on port 4000, and sends the message 'Ahoj' to user bosa. Option -v turns verbose mode on. Xtell will then display some messgaes about connecting, which is usefull especially when the connection is slow. Example: prompt:~% xtell -v rybar@dmpc.dbp.fmph.uniba.sk xtell invoked without parameters will ask user for username and host to send the message to. If the user has created in his/her/its home directory the file .xtell-log, and the file is writable by nobody, all messages will be written to this file as well as to the screen (handy when the screen is overwritten and you could not see the message). xtell checks the environmental variable XTELLPROMPT. If it exists, it is used as prompt for messages. Last notice: if you do not think zsh is the best shell, (besides doing a mistake) replace prompt:~% in above text with prompt:~$ or what- ever :-) AUTHOR
Radovan Garabik (garabik@melkor.dnp.fmph.uniba.sk) SEE ALSO
xtelld(8), write(1), talk(1), talkd(8), tty(1) BUGS
What happens to .xtell-log when two messages arrive simultaneously? There is no locking implemented. XTELL(1)
All times are GMT -4. The time now is 04:07 AM.
Unix & Linux Forums Content Copyright 1993-2022. All Rights Reserved.
Privacy Policy