• Open Menu Close Menu
  • Apple
  • Shopping Bag
  • Apple
  • Mac
  • iPad
  • iPhone
  • Watch
  • TV
  • Music
  • Support
  • Search apple.com
  • Shopping Bag

Lists

Open Menu Close Menu
  • Terms and Conditions
  • Lists hosted on this site
  • Email the Postmaster
  • Tips for posting to public mailing lists
Re: how can I reliably query the correct terminal window?
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: how can I reliably query the correct terminal window?


  • Subject: Re: how can I reliably query the correct terminal window?
  • From: Skeeve <email@hidden>
  • Date: Wed, 03 Dec 2008 23:06:56 +0100

Doug McNutt schrieb:

Most interesting. I do ssh's all over the place and I'd like to know how to execute any command "over there" that can change the window name.
Easy. Put this into your .profile
PS1="\033]0;title text here\007...rest of your prompt"
export PS1

You can even use echo, provided it can handle the \033 \007:
/usr/bin/echo "\033]0;title text here\007\c"

I usually have this prompt:

PS1="\033]0;\h\007\033[7m \u@\h:\w \033[0m\n\$ "

on remote machines and

PS1="\033]0;\w\007\033[7m \u@\h:\w \033[0m\n\$ "

on my local machine

The first gives the hostname in the title, the second my current path.

_______________________________________________
Do not post admin requests to the list. They will be ignored.
AppleScript-Users mailing list      (email@hidden)
Help/Unsubscribe/Update your Subscription:
Archives: http://lists.apple.com/archives/applescript-users

This email sent to email@hidden
  • Follow-Ups:
    • Re: how can I reliably query the correct terminal window?
      • From: "Mark J. Reed" <email@hidden>
References: 
 >how can I reliably query the correct terminal window? (From: Skeeve <email@hidden>)
 >Re: how can I reliably query the correct terminal window? (From: "Mark J. Reed" <email@hidden>)
 >Re: how can I reliably query the correct terminal window? (From: Doug McNutt <email@hidden>)
 >Re: how can I reliably query the correct terminal window? (From: Skeeve <email@hidden>)
 >Re: how can I reliably query the correct terminal window? (From: Doug McNutt <email@hidden>)

  • Prev by Date: Re: how can I reliably query the correct terminal window?
  • Next by Date: Re: how can I reliably query the correct terminal window?
  • Previous by thread: Re: how can I reliably query the correct terminal window?
  • Next by thread: Re: how can I reliably query the correct terminal window?
  • Index(es):
    • Date
    • Thread