| OLD | NEW |
| 1 #!/usr/bin/env dart | 1 #!/usr/bin/env dart |
| 2 // Copyright (c) 2015, the Dart project authors. Please see the AUTHORS file | 2 // Copyright (c) 2015, 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 /// Command line tool to run the checker on a Dart program. | 6 /// Command line tool to run the checker on a Dart program. |
| 7 library dev_compiler.bin.checker; | 7 library dev_compiler.bin.devc; |
| 8 | 8 |
| 9 import 'dart:io'; | 9 import 'dart:io'; |
| 10 | 10 |
| 11 import 'package:dev_compiler/devc.dart'; | 11 import 'package:dev_compiler/devc.dart'; |
| 12 import 'package:dev_compiler/src/options.dart'; | 12 import 'package:dev_compiler/src/options.dart'; |
| 13 | 13 |
| 14 void _showUsageAndExit() { | 14 void _showUsageAndExit() { |
| 15 print('usage: dartdevc [<options>] <file.dart>\n'); | 15 print('usage: dartdevc [<options>] <file.dart>\n'); |
| 16 print('<file.dart> is a single Dart file to process.\n'); | 16 print('<file.dart> is a single Dart file to process.\n'); |
| 17 print('<options> include:\n'); | 17 print('<options> include:\n'); |
| (...skipping 19 matching lines...) Expand all Loading... |
| 37 | 37 |
| 38 setupLogger(options.logLevel, print); | 38 setupLogger(options.logLevel, print); |
| 39 | 39 |
| 40 if (options.serverMode) { | 40 if (options.serverMode) { |
| 41 new CompilerServer(options).start(); | 41 new CompilerServer(options).start(); |
| 42 } else { | 42 } else { |
| 43 var result = new Compiler(options).run(); | 43 var result = new Compiler(options).run(); |
| 44 exit(result.failure ? 1 : 0); | 44 exit(result.failure ? 1 : 0); |
| 45 } | 45 } |
| 46 } | 46 } |
| OLD | NEW |