feat(zinit): integrate zinit for improved shell configuration #1

Merged
vokhactri merged 17 commits from feat/zinit into main 2025-04-18 20:50:42 +07:00
5 changed files with 42 additions and 10 deletions
Showing only changes of commit 70a2f649be - Show all commits

No files matched your search

+5
View File
@@ -3,3 +3,8 @@
[user]
name = Tri Vo Khac
email = 33442340+vokhactri@users.noreply.github.com
[filter "lfs"]
required = true
clean = git-lfs clean -- %f
smudge = git-lfs smudge -- %f
process = git-lfs filter-process
+7 -7
View File
@@ -7,7 +7,7 @@ zinit wait lucid light-mode for \
hlissner/zsh-autopair \
Aloxaf/fzf-tab \
atinit"zicompinit; zicdreplay -q" \
zdharma-continuum/fast-syntax-highlighting zap-zsh/supercharge \
zdharma-continuum/fast-syntax-highlighting \
atload"_zsh_autosuggest_start" \
zsh-users/zsh-autosuggestions \
blockf atpull'zinit creinstall -q .' \
@@ -21,9 +21,9 @@ zinit light starship/starship
# load binaries
zinit as"command" wait lucid light-mode from"gh-r" for \
extract"!" atload="alias cat=bat" lsd-rs/lsd \
extract"!" atload="alias nano=micro" zyedidia/micro \
extract"!" cp"autocomplete/bat.zsh -> _bat" atload"alias cat=bat" @sharkdp/bat \
extract"!" lsd-rs/lsd \
extract"!" zyedidia/micro \
extract"!" cp"autocomplete/bat.zsh -> _bat" @sharkdp/bat \
extract"!" atclone="cp usr/bin/fastfetch .; rm -rf usr" \
fastfetch-cli/fastfetch \
atclone"./zoxide init zsh > init.zsh" atpull"%atclone" src"init.zsh" \
@@ -32,7 +32,7 @@ zinit as"command" wait lucid light-mode from"gh-r" for \
junegunn/fzf \
atclone"./fnm env --use-on-cd > init.zsh" atpull"%atclone" src"init.zsh" Schniz/fnm
# load local snippets
# load local scripts
source $ZDOTDIR/exports.zsh
zstyle ':fzf-tab:complete:cd:*' fzf-preview 'lsd -1 --color=always --icon=always $realpath'
source $ZDOTDIR/aliases.zsh
source $ZDOTDIR/options.zsh
+2 -2
View File
@@ -1,4 +1,4 @@
#!/usr/bin/env zsh
(($+commands[bat])) && alias cat="bat"
(($+commands[lsd])) && alias ls="lsd"
alias cat="bat"
alias ls="lsd"
+1 -1
View File
@@ -6,7 +6,7 @@ SAVEHIST=1000000
export MANWIDTH=999
export EDITOR="micro"
export PAGE="bat"
export PAGER="bat"
export VISUAL="micro"
export SUDO_EDITOR="micro"
+27
View File
@@ -0,0 +1,27 @@
unsetopt BEEP
setopt AUTO_CD
setopt GLOB_DOTS
setopt NOMATCH
setopt MENU_COMPLETE
setopt EXTENDED_GLOB
setopt INTERACTIVE_COMMENTS
setopt APPEND_HISTORY
HISTFILE="${ZDOTDIR:-$HOME}/.zsh_history"
HISTSIZE=5000000
SAVEHIST=5000000
HIST_STAMPS="dd.mm.yyyy"
setopt BANG_HIST # Treat the '!' character specially during expansion.
setopt EXTENDED_HISTORY # Write the history file in the ":start:elapsed;command" format.
setopt INC_APPEND_HISTORY # Write to the history file immediately, not when the shell exits.
setopt SHARE_HISTORY # Share history between all sessions.
setopt HIST_EXPIRE_DUPS_FIRST # Expire duplicate entries first when trimming history.
setopt HIST_IGNORE_DUPS # Don't record an entry that was just recorded again.
setopt HIST_IGNORE_ALL_DUPS # Delete old recorded entry if new entry is a duplicate.
setopt HIST_FIND_NO_DUPS # Do not display a line previously found.
setopt HIST_IGNORE_SPACE # Don't record an entry starting with a space.
setopt HIST_SAVE_NO_DUPS # Don't write duplicate entries in the history file.
setopt HIST_REDUCE_BLANKS # Remove superfluous blanks before recording entry.
setopt HIST_VERIFY # Don't execute immediately upon history expansion.
zstyle ':fzf-tab:complete:cd:*' fzf-preview 'lsd -1 --color=always --icon=always $realpath'