The UNIX and Linux Forums  


Go Back   The UNIX and Linux Forums > Top Forums > UNIX for Dummies Questions & Answers
.
google unix.com




View Single Post in the UNIX and Linux Forums - Click on the Thread or Permalink to View Entire Thread -->
  #5 (permalink)  
Old 06-09-2004
zazzybob's Avatar
zazzybob zazzybob is offline Forum Advisor  
Registered Geek
  
 

Join Date: Dec 2003
Location: Melbourne, Australia
Posts: 2,100
Hi, maybe I should have elaborated.

Create a script called, say, set_title.sh

In vi, insert this code....

Code:
#!/bin/sh

echo "^[]0;$*^G"

The ^[ is produced using the keystroke CTRL-V then ESC

The ^G is produced using the keystroke CTRL-G (on some terminals CTRL-V then CTRL-G)

Then, invoke the code at the prompt with

./set_title.sh My new window title

Cheers
ZB

Last edited by zazzybob; 06-09-2004 at 08:53 AM..