New Macs already include zsh
by default, so what we only need is to run the following command:
Install oh-my-zsh
sh -c "$(curl -fsSL https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)"
The first step created us the following the /.oh-my-zsh
directory
echo $ZSH_CUSTOM
>> /Users/<your home directory>/.oh-my-zsh/custom
Install autosuggestions plugin
git clone https://github.com/zsh-users/zsh-autosuggestions ${ZSH_CUSTOM:-~/.oh-my-zsh/custom}/plugins/zsh-autosuggestions
That command will copy the zsh-autosuggestions repo into /Users/<your home directory>/.oh-my-zsh/custom/plugins
Now we are going to add new plugin by opening the file ~/.zshrc
and add the zsh-autosuggestions
plugin without commas
plugins=(
# other plugins...
zsh-autosuggestions
)
Restart your terminal and now when you type a command that you used previously you will see that now it will auto suggest you using a gray text.
Top comments (0)