mirror of
https://github.com/boxpositron/absolute-dotfiles.git
synced 2026-02-28 11:40:37 +00:00
fix(zshrc): add check for batcat instead of bat before setting cat alias
chore(zshrc): improve error message when bat is not installed
This commit is contained in:
7
.zshrc
7
.zshrc
@@ -141,7 +141,12 @@ fi
|
|||||||
if [ -x "$(command -v bat)" ]; then
|
if [ -x "$(command -v bat)" ]; then
|
||||||
alias cat="bat --theme=\$(defaults read -globalDomain AppleInterfaceStyle &> /dev/null && echo ansi || echo base16)"
|
alias cat="bat --theme=\$(defaults read -globalDomain AppleInterfaceStyle &> /dev/null && echo ansi || echo base16)"
|
||||||
else
|
else
|
||||||
echo "bat is not installed. Please install it to use the custom cat command."
|
|
||||||
|
if [-x "$(command -v batcat)"]; then
|
||||||
|
alias cat="batcat"
|
||||||
|
else
|
||||||
|
echo "bat is not installed. Please install it to use the custom cat command."
|
||||||
|
fi
|
||||||
fi
|
fi
|
||||||
|
|
||||||
# alias vim to neovim
|
# alias vim to neovim
|
||||||
|
|||||||
Reference in New Issue
Block a user