Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 497902 - allow emerge to update title on st terminal
Summary: allow emerge to update title on st terminal
Status: UNCONFIRMED
Alias: None
Product: Portage Development
Classification: Unclassified
Component: Core - Interface (emerge) (show other bugs)
Hardware: All Linux
: Normal normal (vote)
Assignee: Portage team
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2014-01-12 15:45 UTC by Amadeusz Sławiński
Modified: 2014-01-27 11:28 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Amadeusz Sławiński 2014-01-12 15:45:30 UTC
http://st.suckless.org/

st allows updating of window title, however seems like emerge ignores this functionality

It would be nice if it could be added.
st uses same escape sequence as xterm
echo -e "\e]0;window title\a"; sleep 3

% echo $TERM
st-256color

.terminfo/s/st           .terminfo/s/st-meta
.terminfo/s/st-256color  .terminfo/s/st-meta-256color


Reproducible: Always
Comment 1 Brian Dolbec (RETIRED) gentoo-dev 2014-01-27 01:03:15 UTC
It looks like it simply needs to add them to line 235 in pym/portage/output.py.

Can you please confirm that it works properly for you.


diff --git a/pym/portage/output.py b/pym/portage/output.py
index fc1b042..927749a 100644
@@ -232,7 +232,7 @@ def nc_len(mystr):
 	tmp = re.sub(esc_seq + "^m]+m", "", mystr);
 	return len(tmp)
 
-_legal_terms_re = re.compile(r'^(xterm|xterm-color|Eterm|aterm|rxvt|screen|kterm|rxvt-unicode|gnome|interix)')
+_legal_terms_re = re.compile(r'^(xterm|xterm-color|Eterm|aterm|rxvt|screen|kterm|rxvt-unicode|gnome|interix|st|st-meta|st-256color|st-meta-256color)')
 _disable_xtermTitle = None
 _max_xtermTitle_len = 253
Comment 2 Amadeusz Sławiński 2014-01-27 11:28:58 UTC
Yes it works and seeing that it is a regexp match adding 'st' seems to be enough