- Community Home
- >
- Servers and Operating Systems
- >
- Operating Systems
- >
- Operating System - HP-UX
- >
- Re: xterm window title
Categories
Company
Local Language
Forums
Discussions
Forums
- Data Protection and Retention
- Entry Storage Systems
- Legacy
- Midrange and Enterprise Storage
- Storage Networking
- HPE Nimble Storage
Discussions
Discussions
Discussions
Forums
Forums
Discussions
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
- BladeSystem Infrastructure and Application Solutions
- Appliance Servers
- Alpha Servers
- BackOffice Products
- Internet Products
- HPE 9000 and HPE e3000 Servers
- Networking
- Netservers
- Secure OS Software for Linux
- Server Management (Insight Manager 7)
- Windows Server 2003
- Operating System - Tru64 Unix
- ProLiant Deployment and Provisioning
- Linux-Based Community / Regional
- Microsoft System Center Integration
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Discussion Boards
Community
Resources
Forums
Blogs
- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-19-2009 11:02 AM
тАО07-19-2009 11:02 AM
Solved! Go to Solution.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-19-2009 12:52 PM
тАО07-19-2009 12:52 PM
Solutionhttp://www.shelldorado.com/shelltips/beginner.html
several references to that topic there, including the following:
The title of a XTERM window can be set using the following
escape sequence:
ESC ] 0 ; title ^G
Example:
echo "^[]0;This is a title^G"
Enter the escape character (the first character of the
string) as CTRL-V ESC. On the screen you will see "^[". The
last character is entered as CTRL-V CTRL-G.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-19-2009 12:55 PM
тАО07-19-2009 12:55 PM
Re: xterm window title
does these:
esc+ "]2;"+ "Window Title Text"+ bel
esc+ "]1;"+ "Icon Title Text"+ bel
where esc = 27, and bel = 7.
You'll need to reform the expressions for use
in a UNIX shell.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-20-2009 04:28 AM
тАО07-20-2009 04:28 AM
Re: xterm window title
export PS1="^[]0;`hostname | cut -d. -f1`:^G^M`tput bold``hostname | cut -d. \
-f1``tput rmso`":'$PWD# '
The problem is that when I move cursor to the far right corner of the screen it tries to fold line too early (it seems by the hostname string characters). What is the best way to overcome this and have cursor reach the screen till the end?
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-20-2009 07:23 PM
тАО07-20-2009 07:23 PM
Re: xterm window title
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-21-2009 02:26 AM
тАО07-21-2009 02:26 AM
Re: xterm window title
Ok but that doesn't solve the issue. With the title line you can just put ^M, but with the hostname in prompt there is still a problem.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-21-2009 07:23 AM
тАО07-21-2009 07:23 AM
Re: xterm window title
As I said, there is no reason to waste screen real estate with long prompts. I put the hostname in the title and the icon title.
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
тАО07-21-2009 10:44 AM
тАО07-21-2009 10:44 AM