| OLD | NEW |
| 1 #!/bin/bash | 1 #!/bin/bash |
| 2 # Copyright (c) 2017, the Dart project authors. Please see the AUTHORS file | 2 # Copyright (c) 2017, the Dart project authors. Please see the AUTHORS file |
| 3 # for details. All rights reserved. Use of this source code is governed by a | 3 # for details. All rights reserved. Use of this source code is governed by a |
| 4 # BSD-style license that can be found in the LICENSE file. | 4 # BSD-style license that can be found in the LICENSE file. |
| 5 | 5 |
| 6 set -e | 6 set -e |
| 7 | 7 |
| 8 REPO_DIR="$(git rev-parse --show-toplevel)" | 8 REPO_DIR="$(git rev-parse --show-toplevel)" |
| 9 | 9 |
| 10 # TODO(ahe): We currently rely on the Dart VM wrapper script to define | 10 # TODO(ahe): We currently rely on the Dart VM wrapper script to define |
| (...skipping 29 matching lines...) Expand all Loading... |
| 40 dump-ir) | 40 dump-ir) |
| 41 SCRIPT="${KERNEL_BIN}/dump.dart" | 41 SCRIPT="${KERNEL_BIN}/dump.dart" |
| 42 if [ "$#" = "2" ]; then | 42 if [ "$#" = "2" ]; then |
| 43 # Write to stdout if no target is given. | 43 # Write to stdout if no target is given. |
| 44 set -- "$@" /dev/fd/1 | 44 set -- "$@" /dev/fd/1 |
| 45 fi | 45 fi |
| 46 if [ "$#" != "3" ]; then | 46 if [ "$#" != "3" ]; then |
| 47 stop "Usage: $1 dillfile [output]" | 47 stop "Usage: $1 dillfile [output]" |
| 48 fi | 48 fi |
| 49 ;; | 49 ;; |
| 50 generate-messages) SCRIPT="${TOOL_DIR}/generate_messages.dart";; |
| 50 *) | 51 *) |
| 51 stop "'$1' isn't a valid subcommand." | 52 stop "'$1' isn't a valid subcommand." |
| 52 ;; | 53 ;; |
| 53 esac | 54 esac |
| 54 | 55 |
| 55 shift | 56 shift |
| 56 | 57 |
| 57 exec "${DART_VM}" -c "${SCRIPT}" "$@" | 58 exec "${DART_VM}" -c "${SCRIPT}" "$@" |
| OLD | NEW |