# 安装
/bin/bash -c "$(curl -fsSL <https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh>)"
# 替换brew.git
cd "$(brew --repo)"
git remote set-url origin <https://mirrors.tuna.tsinghua.edu.cn/git/homebrew/brew.git>
# 替换homebrew-core.git
cd "$(brew --repo)/Library/Taps/homebrew/homebrew-core"
git remote set-url origin <https://mirrors.tuna.tsinghua.edu.cn/git/homebrew/homebrew-core.git>
# 刷新源
brew update
sh -c "$(curl -fsSL <https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh>)"
插件在.zshrc
里配置,找到plugins
关键字,加载插件;系统默认加载git
,可以追加内容,如下:
plugins=(
git
z
zsh-autosuggestions
zsh-syntax-highlighting
)
git clone <https://github.com/zsh-users/zsh-autosuggestions> $ZSH_CUSTOM/plugins/zsh-autosuggestions
git clone <https://github.com/zsh-users/zsh-syntax-highlighting> $ZSH_CUSTOM/plugins/zsh-syntax-highlighting
GitHub - romkatv/powerlevel10k: A Zsh theme
JetBrains Mono: A free and open source typeface for developers