From c9f312500264761e43cbbe368e3ed9b3eab4be44 Mon Sep 17 00:00:00 2001 From: Ethan P Date: Tue, 12 May 2020 02:31:41 -0700 Subject: [PATCH] *: Automatically use 'batcat' when 'bat' is missing --- lib/constants.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/constants.sh b/lib/constants.sh index 3047fd5..0bdf86a 100644 --- a/lib/constants.sh +++ b/lib/constants.sh @@ -9,7 +9,7 @@ if [[ -z "$__LIB_CONSTANTS_INITIALIZED" ]]; then __LIB_CONSTANTS_INITIALIZED=true # Constants -EXECUTABLE_BAT="bat" +EXECUTABLE_BAT="$(command -v bat 2>/dev/null || command -v batcat 2>/dev/null || echo "bat")" EXECUTABLE_GIT="git" EXECUTABLE_DELTA="delta" PROGRAM="$(basename "$0" .sh)"