This is the mail archive of the
mailing list for the Cygwin project.
Re: Detect mintty in .zshrc?
On 3/3/2011 7:21 AM, Andy Koppe wrote:
> On 3 March 2011 10:10, Rafael Kitover wrote:
>> I was wondering if there's a way in my .zshrc to determine if the shell
>> is running in mintty or in a regular windows console.
> Check $TERM. It defaults to 'xterm' in mintty and 'cygwin' in the console.
Thank you, that works for me, I put this block at the top of my .zshrc:
if [ "$TERM" = "cygwin" -o "$TERM" = "dumb" ]; then
later I switch on "$RUNNING_IN_CONSOLE" to see if I'm in a real console.
Problem reports: http://cygwin.com/problems.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple