Files
dotfiles/.config/zsh/zshrc.d/00-autoload.zsh
Julian Prein a14478f758 zsh: Add _page_readme_chpwd_handler()
Open READMEs in a pager when going into a directory that contains one.
2022-02-07 04:22:32 +01:00

21 lines
519 B
Bash

autoload -U select-word-style && select-word-style bash
autoload edit-command-line; zle -N edit-command-line
autoload -U add-zsh-hook
(( ! $+aliases[run-help] )) || unalias run-help
autoload -Uz run-help run-help-git zmv
# Load autoloadable functions
if [[ -d "$ZDOTDIR/autoload" ]]; then
# Include all subdirectories
for d in "$ZDOTDIR/autoload/"*(/N); do
fpath=("$d" $fpath)
autoload -Uz -- "" "$d"/[^_.]*(.xN:t)
done
fpath=("$ZDOTDIR/autoload" $fpath)
autoload -Uz -- "" "${fpath[1]}"/[^_.]*(.xN:t)
fi