Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I would like to customize the name of the tab in Tilda (I guess that it doesn't change anything from the Gnome-terminal's behavior), but I can't find the exact sequence ...

so far, I figured out that Bash does it when displaying my PS1 prompt:

echo $PS1
\[\e]0;HELLO\a\]\[\033[01;32m\]\u\[\033[00m\]@\[\033[1;35m\]\h\[\033[00m\]:\[\033[01;34m\]\[\033[00m\]

I guess that \[\e]0;HELLO\a\] is responsible for the title to be set to 'HELLO', but when I start

echo -ne "\[\e]0;HELLO WORLD\a\]"

only writes '[]'

what's wrong with my command ?

share|improve this question

2 Answers 2

Your command seems to be incomplete. Have a look at Color_Bash_Prompt. It is explained well there.

share|improve this answer

Wait, I've been stupid:

echo -ne "\e]0;HELLO WORLD\a"

is actually working perfectly, but my "HELLO WORLD" was immediately overwritten by the "HELLO" from the prompt ! Just set

PS1='#' 

or what ever and you'll get you're dynamic title :)

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.