Index: sdk/bin/analyzer |
=================================================================== |
--- sdk/bin/analyzer (revision 0) |
+++ sdk/bin/analyzer (revision 0) |
@@ -0,0 +1,39 @@ |
+#!/bin/bash |
+# Copyright (c) 2013, the Dart project authors. Please see the AUTHORS file |
+# for details. All rights reserved. Use of this source code is governed by a |
+# BSD-style license that can be found in the LICENSE file. |
+ |
+# This file is used to execute the analyzer by running the jar file |
ahe
2013/03/12 15:47:04
Unfinished sentence (add a period).
ricow1
2013/03/12 18:08:40
Done. and in windows as well
|
+# It is a simple wrapper enabling us to have simpler command lines in |
+# the testing infrastructure. |
+set -e |
+ |
+function follow_links() { |
+ while [ -h "$1" ]; do |
+ # On Mac OS, readlink -f doesn't work. |
+ 1="$(readlink "$1")" |
+ done |
+ echo "$1" |
+} |
+ |
+# Unlike $0, $BASH_SOURCE points to the absolute path of this file. |
+PROG_NAME="$(follow_links "$BASH_SOURCE")" |
+ |
+# Handle the case where the binary dir has been symlinked to. |
+CUR_DIR="$(follow_links "$(cd "${PROG_NAME%/*}" ; pwd -P)")" |
+ |
+if [ -z "$DART_CONFIGURATION" ]; |
+then |
+ DART_CONFIGURATION="ReleaseIA32" |
+fi |
+ |
+if [[ `uname` == 'Darwin' ]]; |
+then |
+ JAR_DIR="$CUR_DIR"/../../xcodebuild/$DART_CONFIGURATION/new_analyzer |
+else |
+ JAR_DIR="$CUR_DIR"/../../out/$DART_CONFIGURATION/new_analyzer |
+fi |
+ |
+JAR_FILE="$JAR_DIR/new_analyzer.jar" |
+ |
+exec java -jar $JAR_FILE "$@" |
Property changes on: sdk/bin/analyzer |
___________________________________________________________________ |
Added: svn:executable |
+ * |