Skip to content

Commit

Permalink
fix(zsh): alias exa -> eza and setup git-fuzzy aliases
Browse files Browse the repository at this point in the history
  • Loading branch information
schardev committed Sep 12, 2023
1 parent bf8fa41 commit 9cd134a
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 6 deletions.
11 changes: 5 additions & 6 deletions config/zsh/plugins/aliases.zsh
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,6 @@ alias egrep='egrep --color=auto --exclude-dir={.bzr,CVS,.git,.hg,.svn,.idea,.tox
alias fgrep='fgrep --color=auto --exclude-dir={.bzr,CVS,.git,.hg,.svn,.idea,.tox}'
alias grep='grep --color=auto --exclude-dir={.bzr,CVS,.git,.hg,.svn,.idea,.tox}'
alias gti='git' # I quite often mistype `git` as `gti`
alias gf='git fuzzy'
alias pp='pnpm'
alias px='pnpm dlx'
alias pe='pnpm exec'
Expand All @@ -22,11 +21,11 @@ alias v='nvim'
## Use modern replacements for common GNU programs
# {{{
if (( $+commands[exa] )); then
alias ls='exa'
alias l='exa'
alias la='exa -a'
alias ll='exa -lh'
alias lll='exa -lah'
alias ls='eza'
alias l='eza'
alias la='eza -a'
alias ll='eza -lh'
alias lll='eza -lah'
else
alias l='ls --color=auto'
alias la='ls --color=auto -a'
Expand Down
7 changes: 7 additions & 0 deletions scripts/git-setup.sh
Original file line number Diff line number Diff line change
Expand Up @@ -128,6 +128,13 @@ git_plugins() {
git config --global delta.navigate true
git config --global delta.features mellow-barbet # theme
fi

if command -v git-fuzzy &>/dev/null; then
git config --global alias.f 'fuzzy'
git config --global alias.fd 'fuzzy diff'
git config --global alias.fs 'fuzzy status'
git config --global alias.fl 'fuzzy log'
fi
}

# Initial git config setup
Expand Down

1 comment on commit 9cd134a

@schardev
Copy link
Owner Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

exa's maintainer seems to be unresponsive for a long time so the community "deprecated" it in favor of a community maintained fork - eza.

Please sign in to comment.