Make your terminal cool with zsh and prezto


This is Kamijo of the Development Department.
The default shell has been zsh since the macOS "Catalina" last year or so.
I use windows in the company and mac at home, but the usability is different in bash and zsh of wsl.
This time, I'd like to introduce zsh and prezto to wsl(ubuntu) to make the terminal cool? I'll try to make the terminal cool.

Click here for table of contents

  • 1. zsh installation
  • 2.prezto introduction
  • 3. choose a theme
  • 4. at the end

zsh introduction

apt install zsh

When the installation is complete, the


allows you to switch shells.
However, it is troublesome to switch every time, so let's change the login shell.

which zsh

and you will see "/usr/bin/zsh" or something like that.


to change the login shell.

Enter the new value, or press ENTER for the default
Login Shell [/bin/bash]: /user/bin/zsh "<< Type what you just got here.

You have now changed your login shell.

Introduction of prezto

Clone the repository.

git clone --recursive "${ZDOTDIR:-$HOME}/.zprezto"

Set the EXTENDED_GLOB option of zsh.


Create a configuration file.

for rcfile in "${ZDOTDIR:-$HOME}"/.zprezto/runcoms/^; do
ln -s "$rcfile" "${ZDOTDIR:-$HOME}/.${rcfile:t}"

Shell Restart

exec $SHELL -l

If it looks like the image, you have succeeded.

Select a theme

prompt -p

You can preview the theme with
If you decide which theme you want to use, write down "theme" and "parameter" if necessary.

Set the theme to "~/.zpreztorc".

vim ~/.zpreztorc

Per line 119.

zstyle ':prezto:module:prompt' theme 'sorin'

I think that's what it is.
Enter the "theme" and "param" that you just did here.

Example: theme: fade param: blue

zstyle ':prezto:module:prompt' theme 'fade' 'blue'

Rewrite it like this.
Restart the shell, and if the theme is reflected, you've succeeded! Thanks for your help!


I want to be more particular! If you want to be more particular, we recommend the Powerlevel10K theme.
In addition to changing the appearance, you can display a variety of information.
This is just an introduction, so if you're curious, please check it out.