delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2014/04/11/15:13:29

X-Recipient: archive-cygwin AT delorie DOT com
DomainKey-Signature: a=rsa-sha1; c=nofws; d=sourceware.org; h=list-id
:list-unsubscribe:list-subscribe:list-archive:list-post
:list-help:sender:message-id:date:from:mime-version:to:subject
:content-type:content-transfer-encoding; q=dns; s=default; b=oDx
C2GqS18XLCjqoH/rJOuzYH+vYZ/+mFMlJHYa/F56YI/rBky6C9ngN9u4lkYhPpvS
zQMIXN0Xvva4rK/j+6rbDPz2EMyVyd/AspydHbiP6QM7GJgsmnPpVLz2ntD1JCV7
F2avnUl5KlOuRN+riO54EU8WtPcrH9IkFeQ9lAc0=
DKIM-Signature: v=1; a=rsa-sha1; c=relaxed; d=sourceware.org; h=list-id
:list-unsubscribe:list-subscribe:list-archive:list-post
:list-help:sender:message-id:date:from:mime-version:to:subject
:content-type:content-transfer-encoding; s=default; bh=ppq48b1rx
rI3Al6zx1ybIcrRjQw=; b=M2o5AFbK3+GTutLpL8gWqvE7PGyVBg/rAHDk6tBEM
ebg4KTeSt7VIE7GRAlm5tBNIfMGFp2aR/HsvMK2VIcRJJlSsg+hIolRnKYTTKBuL
uldXfPJ/w4jyTCYypjUR655I4jjspTwl2erepyBTK1zMCqCbtEjEI+xcHwnq9Ra1
DE=
Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Id: <cygwin.cygwin.com>
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sourceware.org/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sourceware.org/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com
Authentication-Results: sourceware.org; auth=none
X-Virus-Found: No
X-Spam-SWARE-Status: No, score=1.5 required=5.0 tests=AWL,BAYES_05,SPF_HELO_PASS,SPF_PASS autolearn=ham version=3.3.2
X-HELO: biostat.ucsf.edu
Message-ID: <53483EC3.6010707@biostat.ucsf.edu>
Date: Fri, 11 Apr 2014 12:13:07 -0700
From: Ross Boylan <ross AT biostat DOT ucsf DOT edu>
User-Agent: Mozilla/5.0 (Windows NT 6.1; rv:24.0) Gecko/20100101 Thunderbird/24.4.0
MIME-Version: 1.0
To: cygwin AT cygwin DOT com
Subject: setting cygwin terminal (mintty) title from a very remote system
X-IsSubscribed: yes

I typically connect to systems through several hops; this note is about 
how I managed to set the title of the cygwin terminal to match the 
remote system.  Usually it just shows the name on the first hop only.   
I would love to learn there is a better way to get the same results.

Various internet sources advise things like

echo -ne '\e]0;Title\a'

to set the window title while noting that the default cygwin prompt sets 
this automatically.  This did not work for me initially, but I found a 
way to get it to work.

On the remote system the prompt does not contain any window titling 
commands.

Concretely, my connection sequence looks like this.

 From System A, running Windows 7, launch a cygwin bash shell.
In that shell, ssh to system B.  B's name will appear in the title bar.
 From B ssh to C.  Neither this nor later operations change the title bar.
 From C ssh to D.
On D, run screen.
In screen, run emacs.
In emacs start a (bash) shell.

I want the name of system D to appear in my title bar.
Systems B-D are running various versions of Debian GNU/Linux.
The echo command from within the bash prompt is ineffective.

If I start a new shell from within screen (Ctl-a c), the echo command 
works from there.

I suppose if I built the window setting command into the remote prompt 
things would just work, since I launch emacs from such a prompt.  But 
I'm not sure what that would do if I were not connecting via cygwin.

Ross Boylan

Someone put in a request for a feature to support manually setting the 
title; this was rejected on the grounds that echoing an appropriate 
sequence would do the same thing 
(http://code.google.com/p/mintty/issues/detail?id=241). Unfortunately, 
that does not seem to be true after connecting to a remote system, or at 
least it is not true after the sequence of steps described above. 
http://superuser.com/questions/362227/how-to-change-the-title-of-the-mintty-window 
has a comment that the echo has no effect when issued from within screen.

--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019