fedora.zshrc aktualisiert
This commit is contained in:
+41
-24
@@ -3,20 +3,13 @@ if [[ -r "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh" ]]
|
||||
source "${XDG_CACHE_HOME:-$HOME/.cache}/p10k-instant-prompt-${(%):-%n}.zsh"
|
||||
fi
|
||||
|
||||
# --- Environment ---
|
||||
export EDITOR='nvim'
|
||||
export VISUAL='nvim'
|
||||
export TERM='xterm-256color'
|
||||
|
||||
# Entferne das '/' aus der Definition eines Wortes
|
||||
WORDCHARS='*?_-.[]~=&;!#$%^(){}<>'
|
||||
zstyle ':completion:*' matcher-list 'm:{a-z}={A-Za-z}'
|
||||
zstyle ':completion:*' list-colors "${(s.:.)LS_COLORS}"
|
||||
|
||||
# --- Zinit Setup ---
|
||||
ZINIT_HOME="${XDG_DATA_HOME:-${HOME}/.local/share}/zinit/zinit.git"
|
||||
if [ ! -d "$ZINIT_HOME" ]; then
|
||||
mkdir -p "$(dirname $ZINIT_HOME)"
|
||||
git clone https://github.com/zdharma-continuum/zinit.git "$ZINIT_HOME"
|
||||
fi
|
||||
[ ! -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"
|
||||
|
||||
# --- Plugins ---
|
||||
@@ -35,17 +28,49 @@ zinit cdreplay -q
|
||||
# Fastfetch erst nach dem Prompt-Setup aufrufen
|
||||
(( $+commands[fastfetch] )) && fastfetch --config ~/.config/fastfetch/fastfetch.jsonc
|
||||
|
||||
# --- History & Options ---
|
||||
bindkey -e
|
||||
bindkey "^[[1;5C" forward-word
|
||||
bindkey "^[[1;5D" backward-word
|
||||
bindkey "^[[3~" delete-char
|
||||
bindkey '^[[A' history-substring-search-up
|
||||
bindkey '^[[B' history-substring-search-down
|
||||
#bindkey "$terminfo[kcuu1]" history-substring-search-up
|
||||
#bindkey "$terminfo[kcud1]" history-substring-search-down
|
||||
|
||||
# Shift + Pfeiltasten (verhindert A, B, C, D Ausgabe)
|
||||
bindkey '^[[1;2A' up-line-or-history # Hoch
|
||||
bindkey '^[[1;2B' down-line-or-history # Runter
|
||||
bindkey '^[[1;2C' forward-char # Rechts
|
||||
bindkey '^[[1;2D' backward-char # Links
|
||||
|
||||
HISTSIZE=5000
|
||||
HISTFILE=~/.zsh_history
|
||||
SAVEHIST=$HISTSIZE
|
||||
setopt appendhistory sharehistory hist_ignore_space hist_ignore_all_dups
|
||||
setopt hist_save_no_dups hist_ignore_dups hist_find_no_dups
|
||||
setopt autocd auto_param_slash globdots
|
||||
HISTDUP=erase
|
||||
setopt appendhistory
|
||||
setopt sharehistory
|
||||
setopt hist_ignore_space
|
||||
setopt hist_ignore_all_dups
|
||||
setopt hist_save_no_dups
|
||||
setopt hist_ignore_dups
|
||||
setopt hist_find_no_dups
|
||||
|
||||
setopt autocd
|
||||
setopt auto_param_slash
|
||||
setopt globdots
|
||||
|
||||
# --- Environment ---
|
||||
export EDITOR='nvim'
|
||||
export VISUAL='nvim'
|
||||
export TERM='xterm-256color'
|
||||
|
||||
# Entferne das '/' aus der Definition eines Wortes
|
||||
WORDCHARS='*?_-.[]~=&;!#$%^(){}<>'
|
||||
|
||||
# --- Aliases ---
|
||||
alias c='clear'
|
||||
alias x='exit'
|
||||
alias yay='yay --noconfirm'
|
||||
|
||||
# Check ob eza installiert ist, sonst ls fallback
|
||||
if (( $+commands[eza] )); then
|
||||
@@ -65,12 +90,4 @@ update_system() {
|
||||
echo "--- System Update ---"
|
||||
sudo dnf upgrade --refresh -y && sudo dnf autoremove -y
|
||||
}
|
||||
alias u='update_system'
|
||||
|
||||
# Keybindings
|
||||
bindkey -e
|
||||
bindkey "^[[1;5C" forward-word
|
||||
bindkey "^[[1;5D" backward-word
|
||||
bindkey "^[[3~" delete-char
|
||||
bindkey '^[[A' history-substring-search-up
|
||||
bindkey '^[[B' history-substring-search-down
|
||||
alias u='update_system'
|
||||
Reference in New Issue
Block a user