Monday, July 3, 2017

How to set title for the Terminal in Ubuntu 17.04

1) Go to .bashrc file by executing the below command. Here I'm running the command under /home/ajanthan location.
 ajanthan@ajanthan-Lenovo:~$ sudo vi .bashrc  

2) The add the below code segment and save the changes.
 #Below is to set the terminal title.  
 set-title(){  
  ORIG=$PS1  
   TITLE="\e]2;$@\a"  
    PS1=${ORIG}${TITLE}  
 }  

3) Now execute the below command.


That's it...

1 comment: