Install Zsh and Auto suggestion plugin for Ubuntu
ZSH, also called the Z shell, is an extended version of the Bourne Shell (sh), with plenty of new features, and support for plugins and themes. Since it's based on the same shell as Bash, ZSH has many of the same features, and switching over is a breeze.
This short tutorial guide you to install zsh and auto-suggestions plugin for Ubuntu and replace the original shell
bash. This is my favorite setup for shell.
Step 1 - Install Zsh
Install Zsh using
1sudo apt install zsh -y
Set Zsh as the default shell:
1chsh -s $(which zsh)
Step 2 - Install Oh My Zsh
Oh My Zsh is an open source, community-driven framework for managing your Zsh configuration.
1sh -c "$(curl -fsSL https://raw.github.com/ohmyzsh/ohmyzsh/master/tools/install.sh)"
Step 3 - Install zsh-autosuggestions
Fish-like fast/unobtrusive autosuggestions for zsh. It suggests commands as you type based on history and completions.
1git clone git://github.com/zsh-users/zsh-autosuggestions ~/.oh-my-zsh/custom/plugins/zsh-autosuggestions
Enable autosuggestions: Open
~/.zshrc, find the line starting with
You need to logout and login again, or restart your PC after this step.
- Oh My Zsh: https://ohmyz.sh/.
- Install zsh-autosuggestions https://github.com/zsh-users/zsh-autosuggestions/blob/master/INSTALL.md.
I maintain this note as my instruction for setting up macOS for development. Currently, I apply this on my Macbook Air M1 2020 - 16GB RAM and 512GB SSD.Read more