Beautify you terminal (oh-my-zsh)

Environment

MacBook Air (M1, 2020)

1
2
$ zsh --version
zsh 5.8 (x86_64-apple-darwin21.0)

Install oh-my-zsh

  1. install via curl

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

    In China, try gitee.

    1
    sh -c "$(curl -fsSL https://gitee.com/mirrors/oh-my-zsh/raw/master/tools/install.sh)"
  2. disable auto-update; uncomment the line

    1
    zstyle ':omz:update' mode disabled  # disable automatic updates
  3. change theme (find more official themes here)

    ZSH_THEME="apple"

Plugins for oh-my-zsh

  1. zsh-suggestion

    1
    2
    $ brew install zsh-autosuggestions
    $ echo "source /opt/homebrew/Cellar/zsh-autosuggestions/0.7.0/share/zsh-autosuggestions/zsh-autosuggestions.zsh" >>~/.zshrc
  2. zsh-syntax-highlighting

    1
    2
    $ brew install zsh-syntax-highlighting
    $ echo "source /opt/homebrew/Cellar/zsh-syntax-highlighting/0.7.1/share/zsh-syntax-highlighting/zsh-syntax-highlighting.zsh" >>~/.zshrc

Remember source ~/.zshrc to activate changes.