commit ebe6b3554b3d255c6beb6c8933410ffd49562bf1
parent e44ac420e49524b170857a52ce8dea89cf9f8da7
Author: Milutin Popovic <milutin@popovic.xyz>
Date: Sat, 27 Dec 2025 16:17:47 +0000
new
Diffstat:
2 files changed, 17 insertions(+), 21 deletions(-)
diff --git a/.config/shell/bindings b/.config/shell/bindings
@@ -18,15 +18,13 @@ function zle-keymap-select {
}
zle -N zle-keymap-select
zle-line-init() {
- zle -K viins # initiate 'vi insert' keymap (can be removed if 'bindkey -V' has been set elsewhere)
+ zle -K viins
echo -ne "\e[5 q"
}
zle -N zle-line-init
-echo -ne '\e[5 q' # Usea beam shape cursor on startup
-preexec() { echo -ne '\e[5 q' ;} # use beam shape cursor for each new prompt
+echo -ne '\e[5 q'
+preexec() { echo -ne '\e[5 q' ;}
-# zkbd compatible hash
-# To add other keys to this hash, see: man 5 terminfo
typeset -g -A key
key[Home]="${terminfo[khome]}"
diff --git a/.config/zsh/.zshrc b/.config/zsh/.zshrc
@@ -1,5 +1,9 @@
#!/usr/bin/env zsh
+
+autoload -U colors && colors
+setopt autocd
+
HISTSIZE=10000
SAVEHIST=10000
if [[ ! -f ~/.cache/zsh/.histfile ]]; then
@@ -7,6 +11,7 @@ if [[ ! -f ~/.cache/zsh/.histfile ]]; then
touch ~/.cache/.histfile
fi
HISTFILE=~/.cache/zsh/.histfile
+setopt inc_append_history
color="blue";
if [[ $USER == "root" ]]; then
@@ -18,25 +23,18 @@ if [ ${IN_NIX_SHELL+1} ]; then
fi
PS1=" %B${brackets:0:1} %F{${color}}%B%m%F{white}%B ${brackets:1:2}: %2~%F{white} >%b "
-# vi mode
-bindkey -v
-export KEYTIMEOUT=1
-
source "${XDG_CONFIG_HOME:-$HOME/.config}/shell/bindings"
source "${XDG_CONFIG_HOME:-$HOME/.config}/shell/aliases"
-if [[ -f ${XDG_CONFIG_HOME:-$HOME/.config}/shell/colors ]]; then
- source "${XDG_CONFIG_HOME:-$HOME/.config}/shell/colors"
-fi
-
-zstyle ':completion:*' completer _complete _ignored
-zstyle ':completion:*' list-colors 'di=1;36'
-zstyle ':completion:*' list-prompt %SAt %p: Hit TAB for more, or the character to insert%s
-zstyle ':completion:*' matcher-list 'm:{[:lower:][:upper:]}={[:upper:][:lower:]} r:|[._-]=** r:|=**'
-zstyle :compinstall filename '/home/mika/.config/zsh/.zshrc'
-
-autoload -Uz compinit
+autoload -U compinit
zstyle ':completion:*' menu select
zmodload zsh/complist
-compinit -C
+compinit
+_comp_options+=(globdots)
+
+bindkey -v
+export KEYTIMEOUT=1
+if [[ -f ${XDG_CONFIG_HOME:-$HOME/.config}/shell/colors ]]; then
+ source "${XDG_CONFIG_HOME:-$HOME/.config}/shell/colors"
+fi