Adding style to Linux Console
Although it not seems helpful personalize linux console it helps a lot when you are working in a vps server over putty or other type of connection.
Generally ubuntu comes with a personalized console that is bash(shell), but not all time happens this. Working with a console only white and black could be a mess and get loss of what whe are doing.
Lets use another shell in this case Z shell that’s is really customizable with oh-my-zsh framework, this framework permit use a bast quantity of themes.
In some cases this themes gives us a really helpful information like what hour is it or if we are inside a folder that is using GIT, if the comand could run correctly etc.
So ¿How can I customize my console?
First we have to install zsh in our linux. You can do this with the following comand.
apt install zsh
You can check for more installation methods in the oh-my-zsh github but this is the simplest one.
Before start using Z shell lets check if it was installed with zsh –version
Now lets do z shell our default.
chsh -s $(which zsh)
Well done, now we have zsh installed. You could check it before continue with this commands
Must give us something like this
Must give something like Zsh X.X.X , the x refer to numbers of version you are using.
Oh-myzsh could be installed with curl or wget. Before start installing oh my zsh check if you have installed curl cause its really helpful.
Checking the curl version:
Just in case you have not installed curl:
sudo apt-get install curl
To install via curl:
sh -c "$(curl -fsSL https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)"
sh -c "$(wget -O- https://raw.githubusercontent.com/ohmyzsh/ohmyzsh/master/tools/install.sh)"
In case these commands don’t work check oh my zsh page
Let’s configure zsh
You can configure zsh modifing .zshrc file that is in your ~/ path, in my case I will use vim as my editor, use your preferred one.
cd -- vim .zshrc
By Default Oh-my-zsh comes with some themes but you have to allow one to be used, you may set one of these with ZSH_THEME command.
Lets do that open your .zshrc and set up bira as your theme and save it.
In case you not see any changes in your console try reloading the source with:
Finally, we can install external themes.
An Example could be https://gist.github.com/philFernandez/56f8953722285834cc9000ffcfe103f4
Here you can see that themes folder is located at ~/.oh-my-zsh/themes to install this theme you can copy it here.
Some themes need fonts to be installed, in this case a nerdfont.
I just downloaded 3270 font you can find it here
One Time downloaded we unzip, open it and install it clicking over install button.
Finally, set 3270 or your downloaded font as console font and modify the .zshrc file but this time with ZSH_THEME=”philty” .
Again if you not see any change at your console run source .zshrc in it.