diff --git a/lib/src/logging.dart b/lib/src/logging.dart index 702c7c48f3..fd578fbf9a 100644 --- a/lib/src/logging.dart +++ b/lib/src/logging.dart @@ -1,3 +1,7 @@ +// Copyright (c) 2017, 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. + import 'dart:async'; import 'dart:convert'; import 'dart:io' show stderr, stdout; @@ -6,10 +10,6 @@ import 'package:analyzer/file_system/file_system.dart'; import 'package:cli_util/cli_logging.dart' show Ansi; import 'package:dartdoc/dartdoc.dart'; import 'package:dartdoc/src/dartdoc_options.dart'; -// Copyright (c) 2017, 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. - import 'package:logging/logging.dart'; final _logger = Logger('dartdoc'); @@ -128,7 +128,9 @@ void startLogging(LoggingContext config) { abstract class LoggingContext implements DartdocOptionContextBase { bool get json => optionSet['json'].valueAt(context); + bool get showProgress => optionSet['showProgress'].valueAt(context); + bool get quiet => optionSet['quiet'].valueAt(context); } diff --git a/pubspec.yaml b/pubspec.yaml index 9910d4164d..eb28d5ab55 100644 --- a/pubspec.yaml +++ b/pubspec.yaml @@ -13,18 +13,13 @@ dependencies: cli_util: '>=0.1.4 <0.3.0' crypto: ^2.0.6 html: '>=0.12.1 <0.15.0' - # We don't use http_parser directly; this dep exists to ensure that we get at - # least version 3.0.3 to work around an issue with 3.0.2. - http_parser: '>=3.0.3 <4.0.0' logging: ^0.11.3+1 - process: ^3.0.5 markdown: ^2.1.5 meta: ^1.1.8 mustache: ^1.1.0 package_config: '>=0.1.5 <2.0.0' path: ^1.3.0 pub_semver: ^1.3.7 - stack_trace: ^1.4.2 yaml: ^2.1.0 dev_dependencies: @@ -36,7 +31,6 @@ dev_dependencies: dhttpd: ^3.0.0 glob: ^1.1.5 grinder: ^0.8.2 - io: ^0.3.0 http: ^0.12.0 mockito: ^4.1.1 pedantic: ^1.9.0 diff --git a/tool/grind.dart b/tool/grind.dart index 89e0d3e824..0a5d5a9cb8 100644 --- a/tool/grind.dart +++ b/tool/grind.dart @@ -9,7 +9,6 @@ import 'package:analyzer/file_system/physical_file_system.dart'; import 'package:dartdoc/src/io_utils.dart'; import 'package:dartdoc/src/package_meta.dart'; import 'package:grinder/grinder.dart'; -import 'package:io/io.dart'; import 'package:path/path.dart' as path; import 'package:yaml/yaml.dart' as yaml; @@ -130,6 +129,7 @@ Directory get testPackageDocsDir => _testPackageDocsDir ??= createTempSync('test_package'); Directory _testPackageExperimentsDocsDir; + Directory get testPackageExperimentsDocsDir => _testPackageExperimentsDocsDir ??= createTempSync('test_package_experiments'); @@ -761,7 +761,7 @@ class FlutterRepo { static Future copyFromExistingFlutterRepo( FlutterRepo origRepo, String flutterPath, Map env, [String label]) async { - await copyPath(origRepo.flutterPath, flutterPath); + copy(Directory(origRepo.flutterPath), Directory(flutterPath)); var flutterRepo = FlutterRepo._(flutterPath, env, label); return flutterRepo; } @@ -826,7 +826,7 @@ Future _buildPubPackageDocs( var pubPackageDirOrig = cache.listSync().firstWhere((e) => e.path.contains(pubPackageName)); var pubPackageDir = Directory.systemTemp.createTempSync(pubPackageName); - await copyPath(pubPackageDirOrig.path, pubPackageDir.path); + copy(pubPackageDirOrig, pubPackageDir); if (packageMetaProvider .fromDir(PhysicalResourceProvider.INSTANCE.getFolder(pubPackageDir.path))