Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(371)

Unified Diff: sdk/bin/dartanalyzer

Issue 16068003: Fix dartanalyzer failure to run when there are spaces in the path to the dart-sdk. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: Created 7 years, 7 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sdk/bin/dartanalyzer
diff --git a/sdk/bin/dartanalyzer b/sdk/bin/dartanalyzer
index 3f0f947c1e9bca805031fa7c772674857663ff10..cc33e5c549c7582bfbfa40cbcd000bd1ecaa93f7 100755
--- a/sdk/bin/dartanalyzer
+++ b/sdk/bin/dartanalyzer
@@ -29,16 +29,16 @@ done
DART_SDK=""
if [ $FOUND_SDK = 0 ] ; then
- if [ -f $DART_ANALYZER_HOME/lib/core/core.dart ] ; then
- DART_SDK="--dart-sdk $DART_ANALYZER_HOME"
+ if [ -f "$DART_ANALYZER_HOME/lib/core/core.dart" ] ; then
+ DART_SDK=(--dart-sdk "$DART_ANALYZER_HOME")
else
- DART_SDK_HOME=$(dirname $DART_ANALYZER_HOME)/dart-sdk
- if [ -d $DART_SDK_HOME ] ; then
- DART_SDK="--dart-sdk $DART_SDK_HOME"
+ DART_SDK_HOME=$(dirname "$DART_ANALYZER_HOME")/dart-sdk
+ if [ -d "$DART_SDK_HOME" ] ; then
+ DART_SDK=(--dart-sdk "$DART_SDK_HOME")
else
- DART_SDK_HOME=$(dirname $DART_SDK_HOME)/dart-sdk
- if [ -d $DART_SDK_HOME ] ; then
- DART_SDK="--dart-sdk $DART_SDK_HOME"
+ DART_SDK_HOME=$(dirname "$DART_SDK_HOME")/dart-sdk
+ if [ -d "$DART_SDK_HOME" ] ; then
+ DART_SDK=(--dart-sdk "$DART_SDK_HOME")
else
echo "Couldn't find Dart SDK. Specify with --dart-sdk cmdline argument"
fi
@@ -46,9 +46,9 @@ if [ $FOUND_SDK = 0 ] ; then
fi
fi
-if [ -f $DART_SDK_HOME/util/dartanalyzer/dartanalyzer.jar ] ; then
+if [ -f "$DART_SDK_HOME/util/dartanalyzer/dartanalyzer.jar" ] ; then
DART_ANALYZER_LIBS=$DART_SDK_HOME/util/dartanalyzer
-elif [ -f $DART_ANALYZER_HOME/util/dartanalyzer/dartanalyzer.jar ] ; then
+elif [ -f "$DART_ANALYZER_HOME/util/dartanalyzer/dartanalyzer.jar" ] ; then
DART_ANALYZER_LIBS=$DART_ANALYZER_HOME/util/dartanalyzer
else
echo "Configuration problem. Couldn't find dartanalyzer.jar."
@@ -76,4 +76,4 @@ else
fi
exec java $EXTRA_JVMARGS $DART_JVMARGS -ea -jar \
- "$DART_ANALYZER_LIBS/dartanalyzer.jar" ${DART_SDK} $@
+ "$DART_ANALYZER_LIBS/dartanalyzer.jar" "${DART_SDK[@]}" $@
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698