From 8cf24f19a28df98d5b8efcff9d83b46265328126 Mon Sep 17 00:00:00 2001 From: John D Pell Date: Fri, 17 Sep 2021 23:19:57 -0700 Subject: [PATCH] lib/utilities: lint `_bash-it-component-cache-file()` --- lib/utilities.bash | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/lib/utilities.bash b/lib/utilities.bash index 3a891166..0e648c9f 100644 --- a/lib/utilities.bash +++ b/lib/utilities.bash @@ -85,9 +85,10 @@ function _bash-it-component-help() cat "${file}" } -_bash-it-component-cache-file() { - local component="$(_bash-it-pluralize-component "${1}")" - local file="${BASH_IT}/tmp/cache/${component}" +function _bash-it-component-cache-file() { + local component file + component="$(_bash-it-pluralize-component "${1}")" + file="${BASH_IT}/tmp/cache/${component}" [[ -f "${file}" ]] || mkdir -p "${file%/*}" printf '%s' "${file}" }