#Set a custom name for the current Tab on Mac OS X terminal
Open your ~/.bash_profile
file and add the following lines:
function tabname {
printf "\e]1;$1\a"
}
Then, save the file and close the editor and invoke source ~/.bash_profile
on a terminal window.
From now on, you can set a name to your tab simply using
tabname aSingleWordName
or
tabname "a multiple words name"