Skip to content

Instantly share code, notes, and snippets.

@thehappydinoa
Last active August 5, 2022 19:05
Show Gist options
  • Save thehappydinoa/946ba9bcee783e62a0525c964be5befb to your computer and use it in GitHub Desktop.
Save thehappydinoa/946ba9bcee783e62a0525c964be5befb to your computer and use it in GitHub Desktop.

Setup Terminal (macOS)

Install iTerm website

iTerm2 is an open source replacement for Apple's Terminal. It's highly customizable and comes with a lot of useful features.

brew install --cask iterm2

Install Oh My Zsh repo

Oh My Zsh is an open source, community-driven framework for managing your zsh configuration.

sh -c "$(curl -fsSL https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)"

Configure Oh My Zsh

Your config file is located at ~/.zshrc

nano ~/.zshrc

Install Starship repo

Starship is a minimal, blazing-fast, and infinitely customizable prompt for any shell!

I would also recommend using the Fira Code Nerd Font for additional icons.

brew install starship

Suggested Plugins

z

z allows you to jump quickly to directories that you have visited "frecently." Add it to your Oh My Zsh plugins list.

plugins=( [plugins...] z)

zsh-autosuggestions repo

It suggests commands as you type based on history and completions.

Install with

git clone https://github.com/zsh-users/zsh-autosuggestions ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-autosuggestions

Then add to your plugins list

plugins=( [plugins...] zsh-autosuggestions)

zsh-syntax-highlighting repo

This package provides syntax highlighting for the shell zsh. It enables highlighting of commands whilst they are typed at a zsh prompt into an interactive terminal. This helps in reviewing commands before running them, particularly in catching syntax errors.

Install with

git clone https://github.com/zsh-users/zsh-syntax-highlighting.git ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-syntax-highlighting

Then add to your plugins list

plugins=( [plugins...] zsh-syntax-highlighting)

evalcache (Optional) repo

zsh plugin to cache eval loads to improve shell startup time

Install with

git clone https://github.com/mroth/evalcache ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/evalcache

Then add to your plugins list

plugins=( [plugins...] evalcache)

Then at the bottom of your ~/.zshrc replace existing evals with _evalcache.

Here is my example for the above packages

# Starship
_evalcache starship init zsh
# Pyenv
_evalcache pyenv init -

Full plugins list

After completing above steps your plugins list should look like

plugins=(z zsh-autosuggestions zsh-syntax-highlighting evalcache)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment