[英]zsh name in terminal changed to a number when logged in
I used to see myname@my-Macbook... when I open my Terminal, but recently it changed to myname@192.我曾经在打开终端时看到 myname@my-Macbook...,但最近它更改为 myname@192。 Why did this happen, and is there a way to change it back?
为什么会发生这种情况,有没有办法改回来? Thanks!
谢谢!
Check out what hostname
returns.查看
hostname
返回的内容。 If it returns that number, search for changing the hostname.如果它返回该数字,请搜索更改主机名。 If not, your shell prompt has gotten messed up, and an easy way to fix it is to trash your shell config (
.zshenv
, .zshrc
, etc).如果没有,您的 shell 提示已经搞砸了,修复它的简单方法是删除您的
.zshrc
配置( .zshenv
, .zshrc 等)。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.