Solved

How do I change the title of a cmd_tool window

Posted on 1998-11-12
12
257 Views
Last Modified: 2013-12-27
How do I change the title of a cmd_tool window without opening a new window?  I'm using Solaris CDE and I use the cmd_tool from open windows (because I like it better than the terminal window).  I tried the following and can't get it to work:

echo -n 'ESC]x;stringBEL' > /dev/ttyN

    where:
       ESC is ASCII ESC 0x1b
       BEL is ASCII BEl 0x07
       x is 0 for changing icon name and window title
            1 for icon name only
            2 for window tile only
      N is number of your tty

How do I get N the # of my tty
0
Comment
Question by:clint_cote
  • 6
  • 5
12 Comments
 
LVL 51

Expert Comment

by:ahoffmann
ID: 2007783
 echo -n 'ESC]lstringESC]LstringESC\' > /dev/ttyN

  where l and L stands for Window- and Icon-label

Note that you must use console instead of ttyN for console cmd
0
 

Author Comment

by:clint_cote
ID: 2007784
I'm not sure that I understand where this is being redirected to.
echo -n 'ESC]lstringESC]LstringESC\' > /dev/ttyN
How do I determine N?  Below is the transcript of what I tried.

%: tty -l
/dev/pts/3
%: echo -n 'lstringLstring\' > /dev/tty3ty3
/dev/tty3: Permission denied
%: echo -n '^]lstring^]Lstring^]\' > /dev/ttytty
stringstring%:
0
 
LVL 51

Expert Comment

by:ahoffmann
ID: 2007785
% ... > /dev/pts/3

or simply write is as follows

% ... > `tty -l`
0
Independent Software Vendors: We Want Your Opinion

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

 

Author Comment

by:clint_cote
ID: 2007786
This does not work with a cmd_tool window. It does work with a shell_tool window, but the editing capabilities stink in a shell_tool.
0
 

Author Comment

by:clint_cote
ID: 2007787
This does not work with a cmd_tool window. It does work with a shell_tool window, but the editing capabilities stink in a shell_tool.
0
 
LVL 51

Expert Comment

by:ahoffmann
ID: 2007788
oops, it's too long since using these tools:

& ... > /dev/console

must be needed for a console window (didn' realize that cmd_tool is a console window, sorry)

If this doesn't work too, please post result of:

% tty
% tty -l
0
 

Author Comment

by:clint_cote
ID: 2007789
All I get is stringstring echoed to the prompt.
%echo -n '^[lstring^[Lstring^[\' > /dev/console
just prints it to my console window.


%tty
/dev/pts/4
%tty -l
/dev/pts/4
not on an active synchronous line
0
 

Author Comment

by:clint_cote
ID: 2007790
Adjusted points to 150
0
 
LVL 51

Expert Comment

by:ahoffmann
ID: 2007791
did you miss the closing bracket  ]  after the first 2 ESC ?
0
 

Author Comment

by:clint_cote
ID: 2007792
It works!  I missed the closing bracket.  Thanks!
0
 
LVL 51

Accepted Solution

by:
ahoffmann earned 150 total points
ID: 2007793
so I repost my first answer

   echo -n 'ESC]lstringESC]LstringESC\' > `tty`
or
   echo -n 'ESC]lstringESC]LstringESC\' > /dev/console
0
 
LVL 4

Expert Comment

by:jlms
ID: 2007794
Please award the points!
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Suggested Solutions

Title # Comments Views Activity
Shell script errors 10 143
How to find files recursively in ftp server quickly? 7 127
How to Insert a File Using Text Editor 9 100
unix solaris snoop command 6 121
Installing FreeBSD… FreeBSD is a darling of an operating system. The stability and usability make it a clear choice for servers and desktops (for the cunning). Savvy?  The Ports collection makes available every popular FOSS application and packag…
Using libpcap/Jpcap to capture and send packets on Solaris version (10/11) Library used: 1.      Libpcap (http://www.tcpdump.org) Version 1.2 2.      Jpcap(http://netresearch.ics.uci.edu/kfujii/Jpcap/doc/index.html) Version 0.6 Prerequisite: 1.      GCC …
Learn how to get help with Linux/Unix bash shell commands. Use help to read help documents for built in bash shell commands.: Use man to interface with the online reference manuals for shell commands.: Use man to search man pages for unknown command…
In a previous video, we went over how to export a DynamoDB table into Amazon S3.  In this video, we show how to load the export from S3 into a DynamoDB table.

685 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question