• 终端:iTerm2 download
  • 软件安装器:brew
/usr/bin/ruby -e "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/master/install)"
  • Shell:zsh
#查看系统当前使用的shell
echo $SHELL
#查看系统是否安装了zsh
cat /etc/shells
#安装zsh
brew install zsh
  • 管理zsh:oh my zsh
sh -c "$(curl -fsSL https://raw.github.com/robbyrussell/oh-my-zsh/master/tools/install.sh)"

安装完成以后,默认Shell的~/.bashrc文件默认不再加载了,替代的是~/.zlogin和~/.zshrc。所以如果你在~/.bashrc里配置了某些设置,需要把她们复制到~/.zshrc中。

  • zsh插件:
#安装 zsh-autosuggestions
git clone git://github.com/zsh-users/zsh-autosuggestions $ZSH_CUSTOM/plugins/zsh-autosuggestions

#安装 zsh-syntax-highlighting
git clone https://github.com/zsh-users/zsh-syntax-highlighting.git ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-syntax-highlighting
  • zsh配置文件:
plugins=(git zsh-autosuggestions autojump zsh-syntax-highlighting)
  • zsh主题Agnoster字体:
#下载
https://github.com/powerline/fonts/blob/master/Meslo%20Dotted/Meslo%20LG%20L%20DZ%20Regular%20for%20Powerline.ttf
#macOS下双击加入到字体库
#进入iTerm2设置-Profiles-Text-Font,选择Powerline字体12pt Meslo LG S DZ Regular for Powerline
  • zsh配置文件.zshrc:
# 主题Agnoster
ZSH_THEME="agnoster"
# 最后一行增加
# redefine prompt_context for hiding [email protected]
prompt_context () { }
  • 查找文件:fd
brew install fd
  • 查找文件内容:ag
brew install the_silver_searcher
  • IDE VSCode
brew cask install visual-studio-code