有點無聊的!
需要在bashrc文件中修改ps1變量
gedit ~/.bashrc
修改
if [ "$color_prompt" = yes ]; then PS1='${debian_chroot:+($debian_chroot)}\[\033[01;32m\]\u@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]\$ '
將\u@\h中的\u(表示用戶名)改為預設置的用戶名比如user
if [ "$color_prompt" = yes ]; then PS1='${debian_chroot:+($debian_chroot)}\[\033[01;32m\]user@\h\[\033[00m\]:\[\033[01;34m\]\w\[\033[00m\]\$ '
修改后如圖
也可以修改主機名,也就是@后面的名稱