feat(zsh): switch to starship prompt
This commit is contained in:
parent
afef09e9a8
commit
f39f21b624
|
@ -21,7 +21,6 @@ zsh/*
|
||||||
!zsh/scripts.zsh
|
!zsh/scripts.zsh
|
||||||
!zsh/aliases.zsh
|
!zsh/aliases.zsh
|
||||||
!zsh/completions/.keep
|
!zsh/completions/.keep
|
||||||
!zsh/.p10k.zsh
|
|
||||||
!zsh/ssh-menu
|
!zsh/ssh-menu
|
||||||
!zsh/get-dump
|
!zsh/get-dump
|
||||||
|
|
||||||
|
|
1697
zsh/.p10k.zsh
1697
zsh/.p10k.zsh
File diff suppressed because it is too large
Load Diff
|
@ -7,9 +7,6 @@ getantidote/use-omz # handle OMZ dependencies
|
||||||
ohmyzsh/ohmyzsh path:lib # load OMZ's library
|
ohmyzsh/ohmyzsh path:lib # load OMZ's library
|
||||||
ohmyzsh/ohmyzsh path:plugins/git
|
ohmyzsh/ohmyzsh path:plugins/git
|
||||||
|
|
||||||
# theme
|
|
||||||
romkatv/powerlevel10k
|
|
||||||
|
|
||||||
# popular fish-like plugins
|
# popular fish-like plugins
|
||||||
zsh-users/zsh-autosuggestions
|
zsh-users/zsh-autosuggestions
|
||||||
|
|
||||||
|
|
|
@ -37,6 +37,10 @@ export PATH="$XDG_DATA_HOME/neovim/bin:$PATH"
|
||||||
export PYENV_ROOT="$XDG_DATA_HOME/.pyenv"
|
export PYENV_ROOT="$XDG_DATA_HOME/.pyenv"
|
||||||
command -v pyenv >/dev/null || export PATH="$PYENV_ROOT/bin:$PATH"
|
command -v pyenv >/dev/null || export PATH="$PYENV_ROOT/bin:$PATH"
|
||||||
|
|
||||||
|
# pyenv-virtualenv
|
||||||
|
# leave python promt to starship
|
||||||
|
export PYENV_VIRTUALENV_DISABLE_PROMPT=1
|
||||||
|
|
||||||
# poetry
|
# poetry
|
||||||
export POETRY_HOME="$XDG_DATA_HOME/poetry"
|
export POETRY_HOME="$XDG_DATA_HOME/poetry"
|
||||||
command -v poetry >/dev/null || export PATH="$POETRY_HOME/bin:$PATH"
|
command -v poetry >/dev/null || export PATH="$POETRY_HOME/bin:$PATH"
|
||||||
|
@ -50,3 +54,6 @@ export USER_GID=$(id -g)
|
||||||
|
|
||||||
# name
|
# name
|
||||||
export NAME="Matej Janežič"
|
export NAME="Matej Janežič"
|
||||||
|
|
||||||
|
# starship nest config into a folder, default is ~/.config/startship.toml
|
||||||
|
export STARSHIP_CONFIG="$XDG_CONFIG_HOME/starship/config.toml"
|
||||||
|
|
15
zsh/.zshrc
15
zsh/.zshrc
|
@ -2,13 +2,6 @@
|
||||||
export HISTFILE="$XDG_STATE_HOME/zsh/history"
|
export HISTFILE="$XDG_STATE_HOME/zsh/history"
|
||||||
export HISTSIZE=100
|
export HISTSIZE=100
|
||||||
|
|
||||||
# Enable Powerlevel10k instant prompt. Should stay close to the top of ~/.config/zsh/.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
|
|
||||||
|
|
||||||
## pre plugin load
|
## pre plugin load
|
||||||
# nvm
|
# nvm
|
||||||
export NVM_COMPLETION=true
|
export NVM_COMPLETION=true
|
||||||
|
@ -22,8 +15,9 @@ antidote load
|
||||||
unsetopt autocd
|
unsetopt autocd
|
||||||
|
|
||||||
# pyenv
|
# pyenv
|
||||||
eval "$(pyenv init -)"
|
eval "$(pyenv init - zsh)"
|
||||||
eval "$(pyenv virtualenv-init -)"
|
# https://github.com/pyenv/pyenv-virtualenv/issues/259
|
||||||
|
eval "$(pyenv virtualenv-init - zsh | sed s/precmd/chpwd/g)"
|
||||||
|
|
||||||
# ggman
|
# ggman
|
||||||
eval "$(ggman shellrc)"
|
eval "$(ggman shellrc)"
|
||||||
|
@ -41,5 +35,4 @@ zstyle ':completion:*' cache-path $XDG_CACHE_HOME/zsh/zcompcache
|
||||||
# opam configuration
|
# opam configuration
|
||||||
# [[ ! -r /Users/janezicmatej/.opam/opam-init/init.zsh ]] || source /Users/janezicmatej/.opam/opam-init/init.zsh > /dev/null 2> /dev/null
|
# [[ ! -r /Users/janezicmatej/.opam/opam-init/init.zsh ]] || source /Users/janezicmatej/.opam/opam-init/init.zsh > /dev/null 2> /dev/null
|
||||||
|
|
||||||
# To customize prompt, run `p10k configure` or edit ~/.config/zsh/.p10k.zsh.
|
eval "$(starship init zsh)"
|
||||||
[[ ! -f ~/.config/zsh/.p10k.zsh ]] || source ~/.config/zsh/.p10k.zsh
|
|
||||||
|
|
Loading…
Reference in New Issue