打造高颜值的macOS终端工具

简单记录一下自己的折腾吧

brew安装

第一步应该就是这样,嘻嘻

/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"

调整brew索引

可以使用清华源或者中科大源

# 调整索引
git -C "$(brew --repo)" remote set-url origin https://mirrors.tuna.tsinghua.edu.cn/git/homebrew/brew.git

git -C "$(brew --repo homebrew/core)" remote set-url origin https://mirrors.tuna.tsinghua.edu.cn/git/homebrew/homebrew-core.git

git -C "$(brew --repo homebrew/cask)" remote set-url origin https://mirrors.tuna.tsinghua.edu.cn/git/homebrew/homebrew-cask.git

brew update

# 调整二进制预编译包的镜像
# 临时调整
export HOMEBREW_BOTTLE_DOMAIN=https://mirrors.tuna.tsinghua.edu.cn/homebrew-bottles

# 长期使用(默认已经安装使用zsh)
echo 'export HOMEBREW_BOTTLE_DOMAIN=https://mirrors.tuna.tsinghua.edu.cn/homebrew-bottles' >> ~/.zshrc
source ~/.zshrc

安装iterm2 和 oh-my-zsh

iterm2官网

sh -c "$(curl -fsSL https://raw.githubusercontent.com/robbyrussell/oh-my-zsh/master/tools/install.sh)"

将 iTerm2 自带 theme 修改为 Minimal

WeChatbbe10640070ca555ef5908fce76f3975.png

安装 dracula

git clone https://github.com/dracula/iterm.git

激活 theme
iTerm2 > Preferences > Profiles > Colors Tab

  1. Open the Color Presets... drop-down in the bottom right corner
  2. Select Import... from the list
  3. Select the Dracula.itermcolors file
  4. Select the Dracula from Color Presets...

WeChat1bae0b813ee87c08a45749edfbfff581.png

配置Status bar

默认是禁用,勾选上选中配置,然后在配置页拖取想要的组件即可

WeChata02072a43ec721a05c5c5f2965d605b0.png

终端背景透明

zsh主题选择

ZSH_THEME="robbyrussell"
plugins=(git colorize pip python brew osx)
source $ZSH/oh-my-zsh.sh
source /usr/local/share/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh
source /usr/local/share/zsh-autosuggestions/zsh-autosuggestions.zsh

效果图

WeChat1dc70155d6aabc4e6141c8f59516774d.png

Last modification:October 12th, 2019 at 10:59 pm
搞技术/肝文章不易,恳请随意打赏 OwO

Leave a Comment