From 0d2c7e9a3a3e2c5240ba3015b2a08d7a982f3427 Mon Sep 17 00:00:00 2001 From: Bjorn Regnell Date: Thu, 11 Apr 2013 01:32:44 +0300 Subject: SI-7355 Handle spaces in paths in Windows batch files. Changed "%1%" and %2% to "%~1" and %~2 to allow spaces in paths by surrounding quotes according to advice at: http://stackoverflow.com/questions/473117/pass-path-with-spaces-as-parameter-to-bat-file http://ss64.com/nt/syntax-args.html --- src/compiler/scala/tools/ant/templates/tool-windows.tmpl | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/compiler/scala/tools/ant/templates/tool-windows.tmpl b/src/compiler/scala/tools/ant/templates/tool-windows.tmpl index 411a27b9c7..bd6cf561b9 100644 --- a/src/compiler/scala/tools/ant/templates/tool-windows.tmpl +++ b/src/compiler/scala/tools/ant/templates/tool-windows.tmpl @@ -14,8 +14,9 @@ set _LINE_TOOLCP= :another_param -if "%1%"=="-toolcp" ( - set _LINE_TOOLCP=%2% +rem Use "%~1" to handle spaces in paths. See http://ss64.com/nt/syntax-args.html +if "%~1"=="-toolcp" ( + set _LINE_TOOLCP=%~2 shift shift goto another_param -- cgit v1.2.3