Reset Zsh config?

To reset your zsh configuration, remove all instances of .zshrc and any .zshrc.??? swap files you may have left over from previous edits.

rm -f ~/.zshrc*

Then, close your terminal session and re-open. You should get the "new user" screen. Select the options from the menu prompts to create a new recommended starting point for your .zshrc configuration and add any prompts or other options you need.

That should do it.

Just be sure that zsh is in /etc/shells file.

which zsh

Will verify the path to your zsh shell.

Set the default shell to zsh, if not already done with

chsh -s $(which zsh)

Verify your FPATH contains the zsh functions and site-functions folders.

Hopefully, all is well.


I ended up copying the contents from the template file in the github repo into my ~/.zshrc file that I'd messed up, found here: https://github.com/robbyrussell/oh-my-zsh/blob/master/templates/zshrc.zsh-template


I would just like to add, that in case you are using something like oh-my-zsh, then instead of just deleting the .zshrc file, You need to copy the standard default .zshrc file.

Use this command instead:

cp ~/.oh-my-zsh/templates/zshrc.zsh-template ~/.zshrc

Tags:

Zsh