delorie.com/archives/browse.cgi | search |
X-Recipient: | archive-cygwin AT delorie DOT com |
X-Spam-Check-By: | sourceware.org |
To: | cygwin AT cygwin DOT com |
From: | Andrew Schulman <schulman DOT andrew AT epamail DOT epa DOT gov> |
Subject: | Re: Naming Cygwin Shells |
Date: | Tue, 09 Oct 2007 05:50:20 -0400 |
Lines: | 22 |
Message-ID: | <qrimg31ohe64navq8lasqjg8ldtb98gu1t@4ax.com> |
References: | <13109737 DOT post AT talk DOT nabble DOT com> |
Mime-Version: | 1.0 |
X-Archive: | encrypt |
X-IsSubscribed: | yes |
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 |
> > Simple question here. I am trying to figure out a way to name a cygwin shell > so that I can have multiple windows up doing tails and other such functions > and easily see what system i am looking at. See the section on PROMPTING (and also the PROMPT_COMMAND variable) in the bash manual for general information about what you can put in your bash prompt. To make some of that information go up into the window title, precede it by the magic incantation '\[\033]0;\]' and follow it by '\[\007\]'. I can't remember where I learned this information. For example, start_window_title='\[\033]0;\]' end_window_title='\[\007\]' PS1="${start_window_title}\w${end_window_title}\$" would give you the current working directory (\w) in the title bar. I'm not sure how you'd get the name of the command that's currently executing into the title bar, but it probably could be done. Good luck, Andrew. -- Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple Problem reports: http://cygwin.com/problems.html Documentation: http://cygwin.com/docs.html FAQ: http://cygwin.com/faq/
webmaster | delorie software privacy |
Copyright © 2019 by DJ Delorie | Updated Jul 2019 |