Skip to content

Instantly share code, notes, and snippets.

@woelfle
Last active April 20, 2021 12:02
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save woelfle/70f942cb89c83418b9da527afa9c846f to your computer and use it in GitHub Desktop.
Save woelfle/70f942cb89c83418b9da527afa9c846f to your computer and use it in GitHub Desktop.
zsh config
EDITOR=code
# Enable Powerlevel10k instant prompt. Should stay close to the top of ~/.zshrc.
# # Initialization code that may require console input (password prompts, [y/n]
# # confirmations, etc.) must go above this block; everything else may go below.
if [[ -r "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh" ]]; then
source "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh"
fi
# See https://github.com/romkatv/powerlevel10k for powerlevel10k documentation
# See https://github.com/bhilburn/powerlevel9k for documentation on the powerline9k plugin
# See https://gist.github.com/kevin-smets/8568070
# See https://github.com/bhilburn/powerlevel9k/wiki/Stylizing-Your-Prompt
# See https://medium.com/the-code-review/nerd-fonts-how-to-install-configure-and-remove-programming-fonts-on-a-mac-178833b9daf3
#POWERLEVEL9K_MODE="nerdfont-fontconfig"
POWERLEVEL9K_MODE="nerdfont-complete"
POWERLEVEL9K_INSTALLATION_PATH=$ANTIGEN_BUNDLES/bhilburn/powerlevel9k
POWERLEVEL9K_PROMPT_ON_NEWLINE=true
POWERLEVEL9K_PROMPT_ADD_NEWLINE=true
POWERLEVEL9K_RPROMPT_ON_NEWLINE=true
# POWERLEVEL9K_LEFT_PROMPT_ELEMENTS=(root_indicator context dir dir_writable vcs)
POWERLEVEL9K_LEFT_PROMPT_ELEMENTS=(root_indicator context dir dir_writable vcs)
POWERLEVEL9K_RIGHT_PROMPT_ELEMENTS=(status command_execution_time background_jobs_joined time_joined ram disk_usage ssh)
POWERLEVEL9K_TIME_FORMAT="%D{%H:%M \uE868 %d.%m.%y}"
POWERLEVEL9K_USER_ICON=$'\uF263'
# Give the 'root' indicator which shows whether we are currently root a bit more visibility
POWERLEVEL9K_ROOT_INDICATOR_BACKGROUND="red"
POWERLEVEL9K_ROOT_INDICATOR_FOREGROUND="white"
POWERLEVEL9K_ROOT_ICON=$'\uF198'
DEFAULT_USER=$USER
# See https://github.com/zsh-users/antigen for documentation on antigen
source /usr/local/share/antigen/antigen.zsh
# Load the oh-my-zsh's library.
antigen use oh-my-zsh
# See https://github.com/arialdomartini/oh-my-git for documentation on the oh-my-git plugin
antigen bundle arialdomartini/oh-my-git
# Use the powerline theme for a smart command line
#antigen theme bhilburn/powerlevel9k powerlevel9k
antigen theme romkatv/powerlevel10k powerlevel10k
# Syntax highlighting bundle.
antigen bundle zsh-users/zsh-syntax-highlighting
# Fish-like auto suggestions
antigen bundle zsh-users/zsh-autosuggestions
# Extra zsh completions
antigen bundle zsh-users/zsh-completions
# Some common aliases
antigen bundle common-aliases
antigen bundle node
antigen bundle kubectl
antigen bundle vagrant
# OS specific plugins
if [[ `uname` == 'Darwin' ]]
then
antigen bundle brew
fi
# Tell Antigen that you're done.
antigen apply
setopt MENUCOMPLETE
HISTSIZE=10000
PATH="/snap/bin:$PATH"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment