80 lines
2.8 KiB
Bash
80 lines
2.8 KiB
Bash
export PATH="$HOME/.local/share/nvim/mason/bin:$PATH"
|
|
export PATH="$PATH:/home/jonas/.local/bin"
|
|
export PATH="$HOME/go/bin:$PATH"
|
|
|
|
# History configuration
|
|
HISTFILE=~/.zsh_history
|
|
HISTSIZE=10000
|
|
SAVEHIST=10000
|
|
|
|
setopt APPEND_HISTORY # Append history instead of overwriting
|
|
setopt EXTENDED_HISTORY # Save timestamps
|
|
setopt HIST_FIND_NO_DUPS # Don't show duplicates when searching
|
|
setopt HIST_IGNORE_DUPS # Don't save duplicate commands
|
|
setopt HIST_IGNORE_SPACE # Don't save commands starting with space
|
|
setopt INC_APPEND_HISTORY # Write to history immediately, not at shell exit
|
|
setopt SHARE_HISTORY # Share history between sessions
|
|
|
|
# Completion
|
|
autoload -U compinit && compinit
|
|
zmodload zsh/complist
|
|
|
|
zstyle ':completion:*' menu select # show menu, highlight selection
|
|
zstyle ':completion:*' list-colors ${(s.:.)LS_COLORS} # file-type colors (dirs, executables, etc.)
|
|
zstyle ':completion:*' matcher-list 'm:{a-zA-Z}={A-Za-z}' # case-insensitive matching
|
|
|
|
# Plugins
|
|
source ~/.zsh/plugins/zsh-autosuggestions/zsh-autosuggestions.plugin.zsh
|
|
source ~/.zsh/plugins/zsh-syntax-highlighting/zsh-syntax-highlighting.plugin.zsh
|
|
source ~/.zsh/plugins/zsh-history-substring-search/zsh-history-substring-search.plugin.zsh
|
|
|
|
# zsh-history-substring-search key bindings
|
|
bindkey '^[[A' history-substring-search-up
|
|
bindkey '^[[B' history-substring-search-down
|
|
|
|
# Shift+Enter: insert a literal newline (no \ continuation, no ∙ dots)
|
|
# Requires kitty keyboard protocol enabled in the terminal (already set in wezterm.lua)
|
|
insert-newline() { LBUFFER+=$'\n' }
|
|
zle -N insert-newline
|
|
bindkey '\e[13;2u' insert-newline
|
|
|
|
unsetopt autocd
|
|
|
|
export EDITOR="nvim"
|
|
export VISUAL="nvim"
|
|
export SUDO_EDITOR="nvim"
|
|
export USE_BUILTIN_RIPGREP=0
|
|
export HF_TOKEN=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
|
|
export LLAMA_CACHE="/home/jonas/gguf_models"
|
|
export LD_LIBRARY_PATH="$HOME/.local/lib64${LD_LIBRARY_PATH:+:$LD_LIBRARY_PATH}"
|
|
|
|
export PATH=~/.npm-global/bin:$PATH
|
|
|
|
function y() {
|
|
local tmp="$(mktemp -t "yazi-cwd.XXXXXX")" cwd
|
|
yazi "$@" --cwd-file="$tmp"
|
|
IFS= read -r -d '' cwd < "$tmp"
|
|
[ -n "$cwd" ] && [ "$cwd" != "$PWD" ] && builtin cd -- "$cwd"
|
|
rm -f -- "$tmp"
|
|
}
|
|
|
|
export PYENV_ROOT="$HOME/.pyenv"
|
|
[[ -d $PYENV_ROOT/bin ]] && export PATH="$PYENV_ROOT/bin:$PATH"
|
|
eval "$(pyenv init - zsh)"
|
|
|
|
eval "$(starship init zsh)"
|
|
eval "$(zoxide init zsh)"
|
|
|
|
if command -v tmux &>/dev/null && [ -z "$TMUX" ]; then
|
|
if [ -n "$SSH_CONNECTION" ] || [ -n "$MOSH_SOCK" ]; then
|
|
tmux new-session -As main
|
|
fi
|
|
fi
|
|
|
|
# Android build environment
|
|
export ANDROID_NDK_HOME="$HOME/Android/Sdk/ndk/29.0.14206865"
|
|
export ANDROID_KEYSTORE_PATH="$HOME/projects/brain/upload.jks"
|
|
export ANDROID_KEYSTORE_PASSWORD="ArtHouse5"
|
|
export ANDROID_KEY_ALIAS="upload"
|
|
export ANDROID_KEY_PASSWORD="ArtHouse5"
|