From b7b01105b637cf77248b61d70c036268e2f6f572 Mon Sep 17 00:00:00 2001 From: P. J. McDermott Date: Mon, 01 Sep 2014 14:41:51 -0400 Subject: substvars: Use printf instead of echo --- diff --git a/lib/substvars.sh b/lib/substvars.sh index 457fb9f..55bbee9 100644 --- a/lib/substvars.sh +++ b/lib/substvars.sh @@ -93,7 +93,7 @@ substvars() old_rhs="${rhs}" # Perform the substitution. - name="$(echo "${name}" | tr 'A-Z-' 'a-z_')" + name="$(printf '%s\n' "${name}" | tr 'A-Z-' 'a-z_')" value="$(eval printf '%s\n' "\"\${substvar_${name}}\"")" string="${lhs}${value}${rhs}" depth=$(($depth + 1)) -- cgit v0.9.1