From f06e33f513d4a13198989528b9d1c70467c0383d Mon Sep 17 00:00:00 2001 From: JozanLeClerc Date: Mon, 14 Mar 2022 14:14:08 +0100 Subject: Added cool hook --- .config/zsh/.zshrc | 6 ++++++ .config/zsh/alias.zsh | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) (limited to '.config/zsh') diff --git a/.config/zsh/.zshrc b/.config/zsh/.zshrc index eee7bde..01b8035 100644 --- a/.config/zsh/.zshrc +++ b/.config/zsh/.zshrc @@ -56,6 +56,12 @@ bindkey -M vicmd "j" history-beginning-search-forward autoload edit-command-line && zle -N edit-command-line bindkey "^e" edit-command-line +autoload -U add-zsh-hook +exa_after_cd() { + exa -l --icons --color=always --group-directories-first +} +add-zsh-hook chpwd exa_after_cd + [ -f "$ZDOTDIR"/alias.zsh ] && source "$ZDOTDIR"/alias.zsh [ -f "$ZDOTDIR"/plugins.zsh ] && source "$ZDOTDIR"/plugins.zsh [ -f "$XDG_PACKAGE_HOME"/fzf/shell/completion.zsh ] && source "$XDG_PACKAGE_HOME"/fzf/shell/completion.zsh diff --git a/.config/zsh/alias.zsh b/.config/zsh/alias.zsh index 8f82550..b20a71a 100644 --- a/.config/zsh/alias.zsh +++ b/.config/zsh/alias.zsh @@ -11,7 +11,7 @@ # == ===== ==== == # ======================== -alias exa='exa --color=always --group-directories-first' \ +alias exa='exa --color=always --group-directories-first --icons' \ ls='exa -l' tree() { exa -T $@ | less -- cgit v1.2.3