Skip to content

Instantly share code, notes, and snippets.

@vol1ura
Last active July 3, 2021 10:11
Show Gist options
  • Save vol1ura/2f91109696235e16710baab5e13ea408 to your computer and use it in GitHub Desktop.
Save vol1ura/2f91109696235e16710baab5e13ea408 to your computer and use it in GitHub Desktop.
How to install and configure zsh

How to install and configure zsh

Install on Ubuntu

  1. Install package
$ sudo apt install zsh
  1. Set zsh as a default shell
$ chsh -s $(which zsh)
  1. Install oh-my-zsh
$ sh -c "$(curl -fsSL https://raw.githubusercontent.com/robbyrussell/oh-my-zsh/master/tools/install.sh)"

Check that

  • your shell set to zsh: grep $USER /etc/passwd
  • zsh is a valid login shell: grep zsh /etc/shells
  1. If all is OK, restart your session.

Configure zsh

  1. Check settings
$ vim ~/.zshrc

and add plugins to an array

plugins=(git rails rvm virtualenv docker)
  1. Install zsh-syntax-highlighting plugin

https://github.com/zsh-users/zsh-syntax-highlighting/blob/master/INSTALL.md

  1. Install zsh-autosuggestions plugin

https://github.com/zsh-users/zsh-autosuggestions/blob/master/INSTALL.md

Remember aliases

  1. Common aliases:
$ alias
  1. Rails aliases

https://github.com/ohmyzsh/ohmyzsh/tree/master/plugins/rails

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment