set pager to 'less' if 'bat' is unavailable

This commit is contained in:
Daniel Sommer 2024-10-02 11:18:39 +02:00
parent e9740ecf56
commit 9b55aabb93

View file

@ -23,7 +23,11 @@ export TEMP="/tmp"
export TMPDIR="/tmp" export TMPDIR="/tmp"
export EDITOR="nvim" export EDITOR="nvim"
export VISUAL="nvim" export VISUAL="nvim"
if [[ "$(command bat 2> /dev/null)" ]]; then
export PAGER="bat" export PAGER="bat"
else
export PAGER="less"
fi
# ----- history ----- # # ----- history ----- #
export HISTFILE="$HOME/.zhistory" export HISTFILE="$HOME/.zhistory"