Skip to content

Instantly share code, notes, and snippets.

@romkatv
Last active July 30, 2024 11:08
Show Gist options
  • Save romkatv/7cbab80dcbc639003066bb68b9ae0bbf to your computer and use it in GitHub Desktop.
Save romkatv/7cbab80dcbc639003066bb68b9ae0bbf to your computer and use it in GitHub Desktop.
Pure style for Powerlevel10k

Powerlevel10k can generate the same prompt as Pure.

pure

Installation

git clone https://github.com/romkatv/powerlevel10k.git ~/powerlevel10k
echo 'source ~/powerlevel10k/powerlevel10k.zsh-theme' >>! ~/.zshrc

If you are using a plugin manager, see alternative installation options.

Restart zsh. Configuration wizard will start automatically. If it doesn't, type p10k configure. Choose "Pure" style when asked.

p10k configure style

But why?

Powerlevel10k with Pure style is faster than plain Pure and gives you access to extra features.

  • Powerlevel10k is much faster at fetching Git status. This can make a difference if you are working in a large Git repository, on a slow machine, or on Windows.
  • If you enable Instant Prompt in the configuration wizard, zsh will start instantly even if your ~/.zshrc is sourcing dozens of plugins. Powerlevel10k is effectively reducing zsh startup time while Pure is increasing it.
  • If you enable Transient Prompt in the configuration wizard, prompt will be automatically trimmed down when accepting a command. See demo.
  • Powerlevel10k is almost infinitely configurable, which is evidenced by its ability to emulate Pure given a suitable set of configuration options. When using Powerlevel10k, you can easily add extra information to the prompt, configure right prompt or completely change your shell style.
@romzyk
Copy link

romzyk commented Dec 3, 2019

Yeah. Thanks 👍

@kylewin
Copy link

kylewin commented Aug 14, 2021

Can I have the prompt segments as in the "Lean" option ? I don't see the prompt segments (pyenv, goenv...) in .p10k.zsh when using this "Pure". But I really love this.

@romkatv
Copy link
Author

romkatv commented Aug 15, 2021

@kyledakid Nope. From the FAQ:

Pure style is an exact replication of Pure Zsh theme. It exists to ease the migration for users of this theme. Unless you are one of them, choose Lean style over Pure.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment