environment:oh-my-zsh 插件
Effect:
The original appearance: I feel that there are many elements, and the space is relatively crowded
The current look: a lot simpler
step:
-
Open your theme's config file (my theme is
agnoster
)open /Users/你的家目录/.oh-my-zsh/themes/agnoster.zsh-theme
-
Find
build_prompt
the function and modify its configurationbuild_prompt() { RETVAL=$? prompt_status prompt_virtualenv prompt_aws # prompt_context prompt_dir prompt_git prompt_bzr prompt_hg prompt_end }
For example, I commented the prompt_context attribute here, indicating that I don't want to display the current user and host name, or other context information on the command line. For other configurations, please GPT by yourself.