commit | 74c0bbb8283556ad1208c778a20be3684d1c3a9e | [log] [tgz] |
---|---|---|
author | Lasse R.H. Nielsen <lrn@google.com> | Wed Mar 18 15:23:02 2020 +0100 |
committer | GitHub <noreply@github.com> | Wed Mar 18 15:23:02 2020 +0100 |
tree | 1394938b8c675794aa79f315fb416f2fadf8dc9b | |
parent | c3301f6f64f0c2c1578ed07370f7ac4e35ed00c7 [diff] |
Make `.packages` files be more clever about defaults. (#80) * Make `.packages` files be more clever about defaults. The `PackageConfig` for a `.packages` file now assigns a default language version of 2.7 to all packages, and if the package location ends in `/lib/`, it assumes the package's root directory is the parent directory of that. * Fix test. * Fix another test.
Support for working with Package Configuration files as described in the Package Configuration v2 design document.
The primary libraries are
package_config.dart
: Defines the PackageConfig
class and other types needed to use package configurations.
package_config_discovery.dart
: Provides functions for reading configurations from files, and writing them back out.
The package includes deprecated backwards compatible functionality to work with the .packages
file. This functionality will not be maintained, and will be removed in a future version of this package.