Unverified Commit e60dc301 authored by Ian Hickson's avatar Ian Hickson Committed by GitHub

Update dartdoc driver to match current behaviour (#132078)

parent 9dbd1e98
...@@ -116,7 +116,7 @@ Future<void> main(List<String> arguments) async { ...@@ -116,7 +116,7 @@ Future<void> main(List<String> arguments) async {
final List<String> dartdocBaseArgs = <String>[ final List<String> dartdocBaseArgs = <String>[
'global', 'global',
'run', 'run',
if (args['checked'] as bool) '-c', if (args['checked'] as bool) '--enable-asserts',
'dartdoc', 'dartdoc',
]; ];
...@@ -229,8 +229,7 @@ Future<void> main(List<String> arguments) async { ...@@ -229,8 +229,7 @@ Future<void> main(List<String> arguments) async {
)); ));
printStream(process.stdout, prefix: args['json'] as bool ? '' : 'dartdoc:stdout: ', printStream(process.stdout, prefix: args['json'] as bool ? '' : 'dartdoc:stdout: ',
filter: args['verbose'] as bool ? const <Pattern>[] : <Pattern>[ filter: args['verbose'] as bool ? const <Pattern>[] : <Pattern>[
RegExp(r'^generating docs for library '), // unnecessary verbosity RegExp(r'^Generating docs for library '), // unnecessary verbosity
RegExp(r'^pars'), // unnecessary verbosity
], ],
); );
printStream(process.stderr, prefix: args['json'] as bool ? '' : 'dartdoc:stderr: ', printStream(process.stderr, prefix: args['json'] as bool ? '' : 'dartdoc:stderr: ',
...@@ -259,7 +258,7 @@ ArgParser _createArgsParser() { ...@@ -259,7 +258,7 @@ ArgParser _createArgsParser() {
'filter out some known false positives (off). Shut this off ' 'filter out some known false positives (off). Shut this off '
'locally if you want to address Flutter-specific issues.'); 'locally if you want to address Flutter-specific issues.');
parser.addFlag('checked', abbr: 'c', parser.addFlag('checked', abbr: 'c',
help: 'Run dartdoc in checked mode.'); help: 'Run dartdoc with asserts enabled.');
parser.addFlag('json', parser.addFlag('json',
help: 'Display json-formatted output from dartdoc and skip stdout/stderr prefixing.'); help: 'Display json-formatted output from dartdoc and skip stdout/stderr prefixing.');
parser.addFlag('validate-links', parser.addFlag('validate-links',
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment