OLD | NEW |
1 @echo off | 1 @echo off |
2 rem Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file | 2 rem Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file |
3 rem for details. All rights reserved. Use of this source code is governed by a | 3 rem for details. All rights reserved. Use of this source code is governed by a |
4 rem BSD-style license that can be found in the LICENSE file. | 4 rem BSD-style license that can be found in the LICENSE file. |
5 | 5 |
6 set SCRIPT_DIR=%~dp0 | 6 set SCRIPT_DIR=%~dp0 |
7 if %SCRIPT_DIR:~-1%==\ set SCRIPT_DIR=%SCRIPT_DIR:~0,-1% | 7 if %SCRIPT_DIR:~-1%==\ set SCRIPT_DIR=%SCRIPT_DIR:~0,-1% |
8 | 8 |
9 for %%I in ("%SCRIPT_DIR%\..") do set "DART_ANALYZER_HOME=%%~fI" | 9 for %%I in ("%SCRIPT_DIR%\..") do set "DART_ANALYZER_HOME=%%~fI" |
10 if %DART_ANALYZER_HOME:~-1%==\ set DART_ANALYZER_HOME=%DART_ANALYZER_HOME:~0,-1% | 10 if %DART_ANALYZER_HOME:~-1%==\ set DART_ANALYZER_HOME=%DART_ANALYZER_HOME:~0,-1% |
(...skipping 18 matching lines...) Expand all Loading... |
29 ) else ( | 29 ) else ( |
30 for /f %%j in ('call echo !DART_SDK_HOME!') do set DART_SDK_HOME=%%~dpj\da
rt-sdk | 30 for /f %%j in ('call echo !DART_SDK_HOME!') do set DART_SDK_HOME=%%~dpj\da
rt-sdk |
31 if exist "!DART_SDK_HOME!" ( | 31 if exist "!DART_SDK_HOME!" ( |
32 set DART_SDK=--dart-sdk !DART_SDK_HOME! | 32 set DART_SDK=--dart-sdk !DART_SDK_HOME! |
33 ) else ( | 33 ) else ( |
34 echo Couldn't find Dart SDK. Specify with --dart-sdk cmdline argument | 34 echo Couldn't find Dart SDK. Specify with --dart-sdk cmdline argument |
35 ) | 35 ) |
36 ) | 36 ) |
37 ) | 37 ) |
38 ) | 38 ) |
39 endlocal & set "DART_SDK=%DART_SDK%" & set "DART_SDK_HOME=%DART_SDK_HOME%" | 39 endlocal & set DART_SDK=%DART_SDK% & set DART_SDK_HOME=%DART_SDK_HOME% |
40 | 40 |
41 if exist "%DART_SDK_HOME%\util\dartanalyzer\dartanalyzer.jar" ( | 41 if exist "%DART_SDK_HOME%\util\dartanalyzer\dartanalyzer.jar" ( |
42 set DART_ANALYZER_LIBS="%DART_SDK_HOME%\util\dartanalyzer" | 42 set DART_ANALYZER_LIBS=%DART_SDK_HOME%\util\dartanalyzer |
43 ) else if exist "%DART_ANALYZER_HOME%\util\dartanalyzer\dartanalyzer.jar" ( | 43 ) else if exist "%DART_ANALYZER_HOME%\util\dartanalyzer\dartanalyzer.jar" ( |
44 set DART_ANALYZER_LIBS="%DART_ANALYZER_HOME%\util\dartanalyzer" | 44 set DART_ANALYZER_LIBS=%DART_ANALYZER_HOME%\util\dartanalyzer |
45 ) else ( | 45 ) else ( |
46 echo Configuration problem. Couldn't find dartanalyzer.jar. | 46 echo Configuration problem. Couldn't find dartanalyzer.jar. |
47 exit /b 1 | 47 exit /b 1 |
48 ) | 48 ) |
49 | 49 |
50 setlocal EnableDelayedExpansion | 50 setlocal EnableDelayedExpansion |
51 set EXTRA_JVMARGS=-Xss2M | 51 set EXTRA_JVMARGS=-Xss2M |
52 if [%FOUND_BATCH%] == [1] ( | 52 if [%FOUND_BATCH%] == [1] ( |
53 set EXTRA_JVMARGS=!EXTRA_JVMARGS! -client | 53 set EXTRA_JVMARGS=!EXTRA_JVMARGS! -client |
54 ) | 54 ) |
55 endlocal & set "EXTRA_JVMARGS=%EXTRA_JVMARGS%" | 55 endlocal & set "EXTRA_JVMARGS=%EXTRA_JVMARGS%" |
56 | 56 |
57 java %EXTRA_JVMARGS% %DART_JVMARGS% -ea -jar "%DART_ANALYZER_LIBS%\dartanalyzer.
jar" %DART_SDK% %* | 57 java %EXTRA_JVMARGS% %DART_JVMARGS% -ea -jar "%DART_ANALYZER_LIBS%\dartanalyzer.
jar" %DART_SDK% %* |
OLD | NEW |