on-my-zsh安装

自动安装

wget https://raw.github.com/robbyrussell/oh-my-zsh/master/tools/install.sh -O - | sh

使用 Homebrew 完成 zshzsh completionszsh-syntax-highlighting 的安装

brew install zsh zsh-completions zsh-syntax-highlighting

配置Zsh

cp ~/.oh-my-zsh/templates/zshrc.zsh-template ~/.zshrc

用文本编辑器或 vim 打开 ~/.zshrc 进行以下编辑:

ZSH_THEME=icloud
# Uncomment the following line to change how often to auto-update (in days).
export UPDATE_ZSH_DAYS=30
plugins=(git autojump osx zsh_reload brew colored-man-pages sudo zsh-autosuggestions)

source $ZSH/oh-my-zsh.sh
source /usr/local/share/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh

[[ -s ~/.autojump/etc/profile.d/autojump.sh ]] && . ~/.autojump/etc/profile.d/autojump.sh

Zsh默认Bash环境

chsh -s /bin/zsh

我们将安装 zsh ,其拓展功能和主题将由 oh-my-zsh 提供。其中 Env.sh 文件用于维护别名(aliases),输出(exports)和路径改变(path changes)等等,以免影响~/.zshrc

results matching ""

    No results matching ""