how to insert a title into a window in kshell


 
Thread Tools Search this Thread
Operating Systems Linux how to insert a title into a window in kshell
# 1  
Old 06-03-2010
how to insert a title into a window in kshell

hi all,

i am using a Ubuntu work station. i have following piece of code that works ok. But i cant figure out a way to insert a string call $Name into the title of the window i am opening. As you can see, i tried two different ways without a success. Can someone please help me out here? Smilie


Code:
if [ "`uname`" = "Linux" ]; then
    #xterm -n $i -T $Name -sl 9999 -sb -bg black -fg yellow -geometry 90x24 -exec vi $log/logs/test.txt
    gnome-terminal --window-with-profile=Win --title=$Name -e "vi $log/logs/test.txt " &

else

# 2  
Old 06-04-2010
You need to add double quotes around your title string. For example:
Code:
xterm -n "$i" -T "$Name"

# 3  
Old 06-04-2010
i tried that, still it doesnt put the title i want. i am using Ubuntu 8.04, i dont know if i need to change anything or download anything.
# 4  
Old 06-04-2010
I guess either
Code:
xterm -n "$i $Name"

or
Code:
xterm -T "$i $Name"

Login or Register to Ask a Question

Previous Thread | Next Thread

10 More Discussions You Might Find Interesting

1. Shell Programming and Scripting

Insert title as output of command to appended file if no output from command

I am using UNIX to create a script on our system. I have setup my commands to append their output to an outage file. However, some of the commands return no output and so I would like something to take their place. What I need The following command is placed at the prompt: TICLI... (4 Replies)
Discussion started by: jbrass
4 Replies

2. UNIX for Dummies Questions & Answers

Getting command output to putty window title.

Hi, Last 2 weeks I have searched many forums and i haven't found the answer for the question: How to get all command output to Putty title? Needed it for other programs to know when some jobs on a server is done and is it done right or wrong. Plink stdout and stdin wasn't working, i used many... (1 Reply)
Discussion started by: domagaj
1 Replies

3. Shell Programming and Scripting

Remotely setting putty window title

I have successfully used a script to modify putty's window title for many years. It has worked great in a Solaris 10 environment, using, sh, bash and tcsh. But I've never been able to get it to work in linux :( The script relies on sending escape sequences via gnu echo. The version of echo on... (4 Replies)
Discussion started by: tsreyb
4 Replies

4. Shell Programming and Scripting

How do I Get the Title of My Putty Window (Emulating an XTerm)

I have a Perl script that changes the terminal window title and I would like to reset it to the original value when I am done. We are using Putty which emulates xterm. We are not running X-Windows so I can't use something like xprop (can I?). I'm using XTerm control codes to change the title and I... (2 Replies)
Discussion started by: NateTut
2 Replies

5. Shell Programming and Scripting

Insert Title To Each Lines

I have a command that returns following, but it's missing a title for each line. YOUR FULL NAME YOUR ID YOUR EMAIL YOUR ADDRESS YOUR PHONE Now, I want to add its title to each line: Name: YOUR FULL NAME ID: YOUR ID Email: YOUR EMAIL Address: YOUR ADDRESS Phone:... (2 Replies)
Discussion started by: tqlam
2 Replies

6. UNIX for Advanced & Expert Users

Change title of aixterm window online

Is there any way to change title of aixterm window online? Also is it possible to freeze first/last few lines online? (1 Reply)
Discussion started by: Soham
1 Replies

7. UNIX for Advanced & Expert Users

putty title window?

I have implemented the solution from mschwage located in post https://www.unix.com/unix-advanced-expert-users/35784-change-putty-title-window.html; ie wt () { echo -n "^2;${@}^G" } This method is awesome!!!! The reason I am sending you this message is to get your assistance with... (3 Replies)
Discussion started by: lwif
3 Replies

8. UNIX for Advanced & Expert Users

Change putty title window?

Is it possible to change the putty window title from a Unix command line? (12 Replies)
Discussion started by: akbar
12 Replies

9. UNIX for Dummies Questions & Answers

window title..?

how to echo some text onto the window title bar...in exceed client...so that we can know where we are in..in multiple hostnames kinda..thing.. any advice.. (1 Reply)
Discussion started by: tintedwindow
1 Replies

10. Windows & DOS: Issues & Discussions

window 2000 professional not pinging my window 98 system.

Hello, We someone help me resolve this problem. I have window 2000 professional, windows 98 and Unixware 7.0.1 on the network. I was able to establish connection with all. However, l was unable to ping window 98 from window 2000 professional. I was able to ping the window 2000 from the window... (10 Replies)
Discussion started by: kayode
10 Replies
Login or Register to Ask a Question