Generally speaking, there are many shells under linux, and different shell users have different experiences. Then I was given the ultimate shell in a shell by my apprentice Amway, called oh-my-zsh. I don't know much about this, and I used the default bash at first.
- First look at your own shell
jialu-MacBookPro ~ » cat /etc/shells
# /etc/shells: valid login shells
/bin/sh
/bin/dash
/bin/bash
/bin/rbash
/bin/zsh
/usr/bin/zsh
Look at the shell you own (after zsh has been installed)
2. ubuntu linux install zsh
sudo apt-get install zsh
It seems that the git command clone needs to be used after installation, so users who do not have git need to install git
sudo apt-get install git
(My original git is already installed, skip this step)
- this is an automatic installation
wget https://github.com/robbyrussell/oh-my-zsh/raw/master/tools/install.sh -O - | sh
- Manual installation is divided into two steps
git clone git://github.com/robbyrussell/oh-my-zsh.git ~/.oh-my-zsh
cp ~/.oh-my-zsh/templates/zshrc.zsh-template ~/.zshrc
I read the tutorial, and the installation was successful here, but I encountered a small problem. When installing, I finally prompted to copy the downloaded .zshrc file to the /oh-my-zsh directory, and then restart after copying. There is no change in the terminal, and the directory is deleted and downloaded again, but the problem is still the same, and finally it shuts down. Then. I rebooted last night, opened the shell, my shell is different from before, wow, I installed oh-my-zsh for no reason...
because I thought the installation failed, and there were no screenshots of the problems encountered, so the pit It's not easy to describe, but I tried to solve it according to its English prompts. Finally, it was ok after restarting the computer, indicating that sometimes error prompts are the key to solving the problem.
3. Theme change
Because I opened my terminal at night, I found that the zsh theme was not good-looking than the bash I used before, so I changed the theme before I got up to write a blog today. I also watched the tutorial on changing the theme last night. One way is to open a theme in the oh-my-zsh directory with vim, find the theme code on git, and copy and paste it into it.
jialu-MacBookPro ~ » ls -a
First look at your own hidden files, there is a .zshrc file
jialu-MacBookPro ~ » vim .zshrc
Then open this hidden file with vim
ZSH_THEME="random"
Find this code, change the theme, mine is random... Click
here to view various themes
Pick a favorite, copy the name after the equal sign, save and exit, and restart the shell
ZSH_THEME="af-magic"
Then it's just inexplicable. Listen to the big guys, oh-my-zsh is the ultimate terminal. Let's experience it later...