From 956acd5f5953fe2fa1842dc82a1e2f37d3eb1042 Mon Sep 17 00:00:00 2001 From: Dan Prince Date: Fri, 2 May 2014 13:10:33 -0400 Subject: [PATCH] Eliminate 'tr' in favor of inline bash. Updates the lib/common-functions generate_hooks() function to use bash instead of exec'ing tr. Change-Id: Ie32d3ce5c7c43affd0031a568d57763e36209603 --- lib/common-functions | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/common-functions b/lib/common-functions index 0e1b67bd..2b7e40a7 100644 --- a/lib/common-functions +++ b/lib/common-functions @@ -97,7 +97,7 @@ function first_boot_deprecated_message() { function generate_hooks () { mkdir -p $TMP_HOOKS_PATH for _ELEMENT in $IMAGE_ELEMENT ; do - for dir in $(echo $ELEMENTS_PATH | tr ":" " ") ; do + for dir in ${ELEMENTS_PATH//:/ } ; do element_pre_check $dir/$_ELEMENT || continue cp -t $TMP_HOOKS_PATH -a $dir/$_ELEMENT/* ; break