nano ~/.bashrc 如图所示,将'\u@\h:\w$ '修改为'\u:\w$ ',去掉主机名,以达到有时候截图保护隐私的目的 image.png 执行source ~/.bashrc生效 image.png