support/dependencies/dependencies.sh: simplify an error message
PATCH 1/1 support/dependencies/dependencies.sh: simplify an error message
There is no need to break the "\n" sequence using "%sn". We can just escape it. Note: the escaping backslash needs to be escaped too, because the shell will process the string before printf gets to see it.
Signed-off-by Markus Mayer <[email protected]>
--- support/dependencies/dependencies.sh | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-)
support/dependencies/dependencies.sh +1 -2
@@ -37,8 +37,7 @@ case ":${PATH:-unset}:" in ;; (*" "*) printf "\n" - # Break the '\n' sequence, or a \n is printed (which is not what we want). - printf "Your PATH contains a newline (%sn) character.\n" "\\" + printf "Your PATH contains a newline (\\\n) character.\n" printf "This doesn't work. Fix you PATH.\n" exit 1 ;;
Signature · 1 line
2.17.1
PATCH 1/1 support/dependencies/dependencies.sh: simplify an error message
Quoted 7 lines
Quoted 1 line
Quoted 1 line
Quoted 1 line
Quoted 1 line
"Markus" == Markus Mayer <[email protected]> writes:
There is no need to break the "\n" sequence using "%sn". We can just escape it. Note: the escaping backslash needs to be escaped too, because the shell will process the string before printf gets to see it.
Signed-off-by Markus Mayer <[email protected]>
Maybe we should have used single quotes here to get rid of one layer of quoting.
Committed, thanks.
Quoted 25 lines
--- support/dependencies/dependencies.sh | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-)support/dependencies/dependencies.sh +1
-2@@ -37,8 +37,7 @@ case ":${PATH:-unset}:" in ;; (*" "*) printf "\n" - # Break the '\n' sequence, or a \n is printed (which is not what we want). - printf "Your PATH contains a newline (%sn) character.\n" "\\" + printf "Your PATH contains a newline (\\\n) character.\n" printf "This doesn't work. Fix you PATH.\n" exit 1 ;;Signature · 6 lines
2.17.1 _______________________________________________ buildroot mailing list buildroot at busybox.net http://lists.busybox.net/mailman/listinfo/buildroot
Signature · 1 line
Bye, Peter Korsgaard