Merge pull request #254 from er1c/fix-253

Simplify the debug in execRunner and fix the $java_args[@] expansion fixes #253
This commit is contained in:
eugene yokota 2019-02-05 00:02:00 -05:00 committed by GitHub
commit b28d203910
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 8 deletions

View File

@ -57,14 +57,10 @@ rt_export_file () {
}
execRunner () {
# print the arguments one to a line, quoting any containing spaces
# print the arguments one to a line, shell-quoted
[[ $verbose || $debug ]] && echo "# Executing command line:" && {
for arg; do
if printf "%s\n" "$arg" | grep -q ' '; then
printf "\"%s\"\n" "$arg"
else
printf "%s\n" "$arg"
fi
for arg in "$@"; do
printf "%q\n" "$arg"
done
echo ""
}
@ -348,7 +344,7 @@ run() {
$(get_gc_opts) \
${JAVA_OPTS} \
${SBT_OPTS:-$default_sbt_opts} \
${java_args[@]} \
"${java_args[@]}" \
-jar "$sbt_jar" \
"${sbt_commands[@]}" \
"${residual_args[@]}"