[pacman-dev] [PATCH] Replace "echo" command with "printf" in human_to_size_test.sh
Signed-off-by: Jason St. John <jstjohn@purdue.edu> --- This is a resubmit. Dave suggested using "printf" instead of "echo" here: https://mailman.archlinux.org/pipermail/pacman-dev/2013-November/018183.html test/scripts/human_to_size_test.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/scripts/human_to_size_test.sh b/test/scripts/human_to_size_test.sh index 659d78c..692b89d 100755 --- a/test/scripts/human_to_size_test.sh +++ b/test/scripts/human_to_size_test.sh @@ -5,7 +5,7 @@ declare -i testcount=0 fail=0 pass=0 total=15 # source the library function lib=${1:-${PMTEST_SCRIPTLIB_DIR}human_to_size.sh} if [[ -z $lib || ! -f $lib ]]; then - echo "Bail out! human_to_size library ($lib) could not be located\n" + printf "Bail out! human_to_size library ($lib) could not be located\n" exit 1 fi . "$lib" -- 1.8.4.2
On Fri, Nov 08, 2013 at 11:59:53AM -0500, Jason St. John wrote:
Signed-off-by: Jason St. John <jstjohn@purdue.edu> --- This is a resubmit. Dave suggested using "printf" instead of "echo" here: https://mailman.archlinux.org/pipermail/pacman-dev/2013-November/018183.html
test/scripts/human_to_size_test.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/test/scripts/human_to_size_test.sh b/test/scripts/human_to_size_test.sh index 659d78c..692b89d 100755 --- a/test/scripts/human_to_size_test.sh +++ b/test/scripts/human_to_size_test.sh @@ -5,7 +5,7 @@ declare -i testcount=0 fail=0 pass=0 total=15 # source the library function lib=${1:-${PMTEST_SCRIPTLIB_DIR}human_to_size.sh} if [[ -z $lib || ! -f $lib ]]; then - echo "Bail out! human_to_size library ($lib) could not be located\n" + printf "Bail out! human_to_size library ($lib) could not be located\n"
But this should be using a formatter for "$lib" ...
exit 1 fi . "$lib" -- 1.8.4.2
participants (2)
-
Dave Reisner
-
Jason St. John