Future run()

in dartfn/lib/src/cli/app.dart [61:74]


  Future<void> run(List<String> args) async {
    try {
      await _runner.run(args);
    } catch (e, st) {
      // UsageException comes from the CommandRunner arg parser as well as the
      // individual subcommand implementations. Don't need to print stacktrace.
      // Must force toString() on e or will only print message (without usage).
      if (e is UsageException) {
        return Future.sync(() => context.console.error(e.toString()));
      } else {
        return Future.error(e, st);
      }
    }
  }