My zsh configs

Wrote this to easily find it (updated)

June 20, 2024


Nothing big in this post, just sharing my current zsh config. Recommended to patch your fonts with Nerd Fonts (or use one of their pre-patched fonts).

~/.kushell
# needed for this config:
# zsh
# git

# can be expressed as on Arch:
# yay/paru -S zsh git

ZINIT_HOME="${XDG_DATA_HOME:-${HOME}/.local/share}/zinit/zinit.git"
[ ! -d $ZINIT_HOME ] && mkdir -p "$(dirname $ZINIT_HOME)"
[ ! -d $ZINIT_HOME/.git ] && git clone https://github.com/zdharma-continuum/zinit.git "$ZINIT_HOME"
source "${ZINIT_HOME}/zinit.zsh"

ZSH_AUTOSUGGEST_STRATEGY=(history completion)

# load fzf
zinit ice from"gh-r" as"program"
zinit light junegunn/fzf

zinit snippet OMZP::fzf
# see https://github.com/ohmyzsh/ohmyzsh/tree/master/plugins/command-not-found to find what to install
#zinit snippet OMZP::command-not-found
zinit light zsh-users/zsh-syntax-highlighting
zinit light zsh-users/zsh-autosuggestions
zinit light Aloxaf/fzf-tab

autoload -Uz compinit
compinit

export STARSHIP_CONFIG=~/.kushell-starship.toml
zinit ice as"command" from"gh-r" \
 atclone"./starship init zsh > init.zsh; ./starship completions zsh > \_starship" \
 atpull"%atclone" src"init.zsh"
zinit light starship/starship


~/.kushell-starship.toml
add_newline = false

[character]
success_symbol = '[🌸](green)'
error_symbol = '[✗](bold red)'

[line_break]
disabled = true

[nodejs]
detect_files = ['!video.ts', '!audio.ts']

[cmd_duration]
min_time=0

[zig]
symbol='îš© '

(Now add this to the beginning of your .zshrc)

~/.zshrc
# ...
source ~/.kushell