unix - How do I permanently change the terminal prompt in iTerm2 using zsh? -
in terminal prompt under default profile shows:
last login: sat jun 21 17:43:00 on ttys000 ➜ ~ when type:
➜ ~ export ps1="|%*| ~ " i receive this:
|17:44:11| ~ that's want displayed. how create permanent, won't have type every time?
i have tried following: inserting export ps1="|%*| ~ " .zsh, under prefrences >> profile >> custometheme , default >> command >> checked command inserted export ps1="|%*| ~ " no luck.
this has nil iterm2; it's purely zsh issue.
you need add together command
ps1="|%*| ~ " to $home/.zshrc file.
followup based on comments: best bet add together line @ or near end of .zshrc file. if else in .zshrc settings $ps, either straight or indirectly (by invoking script), want desired value override that.
there's no need export value of $ps1.
there other places set command. see zsh manual (or type info zsh) more details. far can tell, zsh doesn't pay attending .zsh file (unless tell to).
unix command-line terminal command-prompt zsh
No comments:
Post a Comment