Developers use terminal all the time because it is effective than graphical
user interfaces (GUI). Therefore, I spend my time on my lovely terminal, but
the problem is length of hostname. I use default size which is 80x24.
berkhans-thinkpad-t460 has 22 characters… Now, you can imagine that is why
important for me.
I will just share simple snippet that will help you to remove that hostname part.
if [ "$color_prompt" = yes ]; then PS1='\[\033[01;32m\]\u\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]\$ ' else PS1='\u:\w\$ ' fi
All you need to do that add this snippet before
unset color_prompt force_color_prompt
After you restart your terminal, you will have this