[Buildroot] [PATCH] infra: display current task as title of the term window
Arnout Vandecappelle
arnout at mind.be
Mon Aug 19 16:19:17 UTC 2013
On 18/08/13 10:21, Thomas De Schampheleire wrote:
> On Tue, Aug 13, 2013 at 7:36 AM, Arnout Vandecappelle <arnout at mind.be> wrote:
>> On 07/08/13 08:44, Thomas De Schampheleire wrote:
>>>
>
>>> I know that Gentoo has this feature for its portage package
>>> installation/compilation tool. When you run 'emerge', the titles are
>>> constantly updated with the package that is being handled, also in
>>> Konsole. You may be able to find out what the 'right way' is based on
>>> their sources.
>>
>>
>> Are you sure this works for you with emerge? I RTFM'ed it and according to
>> the konsole manual, you have to add '%w' to the tab title string to get the
>> string set by the shell. Perhaps Gentoo simply sets the default tab title
>> string to something including %w.
>>
>
>
> It does work for emerge, but it seems you are right: the default tab
> title in Gentoo is set to %w (I didn't set it explicitly). I tried
> Francois' patch on a non-gentoo system before (didn't work for
> Konsole) but after explicitly setting %w in the tab title it also
> works there. So that issue is cleared out.
>
> However, while testing again, I noticed an annoyance: if the build
> process stops prematurely, for example because the build fails or the
> user interrupts it, the last tab title remains. I would much prefer
> that we can cleanly restore this no matter how buildroot/make stops.
Won't that be the case regardless of whether the build fails or succeeds?
I think this patch is only really suitable for people who have
something similar in their PS1. Otherwise it will just mess up your
window title.
Also, it should only be done if $TERM == xterm, otherwise you get
annoying stuff when running buildroot from a text console. And in fact,
the same is true of the colouring itself, so we don't get these annoying
escape characters in log files and continuous integration web interfaces.
Regards,
Arnout
--
Arnout Vandecappelle arnout at mind be
Senior Embedded Software Architect +32-16-286500
Essensium/Mind http://www.mind.be
G.Geenslaan 9, 3001 Leuven, Belgium BE 872 984 063 RPR Leuven
LinkedIn profile: http://www.linkedin.com/in/arnoutvandecappelle
GPG fingerprint: 7CB5 E4CC 6C2E EFD4 6E3D A754 F963 ECAB 2450 2F1F
More information about the buildroot
mailing list