1

Currently my command line prompt looks like this nuve@nuve-Inspiron-5547:~$ but I want to change it Azer's Terminal:"Path of current directory". How can I do this? I need exact code line to add to bashrc file.

muru
  • 197,895
  • 55
  • 485
  • 740
  • There's an answer to the linked question which shows exactly how to put the current working directory at the end of the prompt. – kos Feb 11 '16 at 12:53

1 Answers1

0

Follow this step ;

  1. Open the terminal
  2. If you don't have a .bashrc file in your $HOME (/home/<username>) , make it with type this command touch $HOME/.bashrc
  3. If you have it, open it with text editor like nano, etc.
  4. add this script in your .bashrc

    PS1='[ \h \W]\$ '
    
  5. To make your hostname such as you want open file /etc/hostname with sudo

    sudo nano /etc/hostname
    
  6. Remove previous hostname and add new hostname which you want in this file

    Azer's Terminal
    
  7. If you have finish , logout or reboot your system to make it affect .

This my .bashrc file enter image description here

muru
  • 197,895
  • 55
  • 485
  • 740