From 889259dfec3df435539841c188321b64ec804e78 Mon Sep 17 00:00:00 2001 From: Ira Abramov Date: Sun, 8 Nov 2020 17:33:21 +0200 Subject: [PATCH] Cut 30s vrom the knife completion init time. --- completion/available/knife.completion.bash | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/completion/available/knife.completion.bash b/completion/available/knife.completion.bash index 6316ce08..def1ccaa 100644 --- a/completion/available/knife.completion.bash +++ b/completion/available/knife.completion.bash @@ -98,7 +98,8 @@ _KAC_clean_cache() } # perform a cache cleaning when loading this file -_KAC_clean_cache +# On big systems this could baloon up to a 30 second run or more, so not enabling by default. +[[ "${KNIFE_CACHE_CLEAN}" ]] && _KAC_clean_cache ##################################### ### End of cache helper functions ###