pubspeccheck 0.0.2

  • README.md
  • CHANGELOG.md
  • Installing
  • Versions
  • 46

PubSpecCheck #

Utility to check the versions of packages in a pubspec.yaml file. Useful to see if there is a shift in major versions (ex: 0.7.0 to 0.8.0) so you can update your version rules inside the pubspec file.

Installation #

To install:

> pub global activate pubspeccheck

To update, run activate again:

> pub global activate pubspeccheck

Usage #

pubspec yourfile.yaml
pubspec -c yourfile.yaml
pubspec -a yourfile.yaml

Example #

If you run the utility on its own pubspec.yaml

> pubspec pubspec.yaml

You will get

[pubspec.yaml]
HostedDependency: ^2.1.15 => 2.1.15 	 yaml
HostedDependency: ^0.1.2+2 => 0.1.2+2 	 pubspec_parse
HostedDependency: ^3.0.0 => 3.0.2 	 pub_client
HostedDependency: ^1.5.0 => 1.5.0 	 args

If a major change is detected, it will give you the link to the changelog to see if there are any breaking changes. Here is an example:

--------- MAJOR DIFFERENCE ---------
Changelog: https://pub.dartlang.org/packages/flutter_inapp_purchase#-changelog-tab-
HostedDependency: 0.7.0 => 0.8.0         flutter_inapp_purchase
------------------------------------
HostedDependency: ^0.5.18 => 0.5.20      firebase_auth

Please note that if you don't use ^ in your yaml file, you will get a notification of a major difference as well.

--------- MAJOR DIFFERENCE ---------
Changelog: https://pub.dartlang.org/packages/flutter_inapp_purchase#-changelog-tab-
HostedDependency: 0.8.0 => 0.8.2         flutter_inapp_purchase
------------------------------------

Show all changelogs #

With the -c flag, all changelogs urls will be shown for packages where the versions are different from those found in the pubspec.yaml file.

With the -a flag, all changelogs will be shown, regardless of version numbers.

For example, when running this:

> pubspec -c pubspec.yaml

You might get something like:

------------------------------------
Changelog: https://pub.dartlang.org/packages/timeago#-changelog-tab-
HostedDependency: ^2.0.1 => 2.0.8        timeago

--------- MAJOR DIFFERENCE ---------
Changelog: https://pub.dartlang.org/packages/flutter_inapp_purchase#-changelog-tab-
HostedDependency: 0.8.0 => 0.8.2         flutter_inapp_purchase
------------------------------------
------------------------------------
No new version, no changelog needed
HostedDependency: ^0.3.2 => 0.3.2        package_info
------------------------------------

Notes #

There is little to no error handling of any kind, this is just a quick and dirty script 🙂

0.0.2 #

  • README fixes, code is the same

0.0.1 #

  • First version that can be run as a binary with command pubspec

Use this package as an executable

1. Install it

You can install the package from the command line:


$ pub global activate pubspeccheck

2. Use it

The package has the following executables:


$ pubspec
Version Uploaded Documentation Archive
0.1.0 Oct 23, 2018 Go to the documentation of pubspeccheck 0.1.0 Download pubspeccheck 0.1.0 archive
0.0.2 Oct 23, 2018 Go to the documentation of pubspeccheck 0.0.2 Download pubspeccheck 0.0.2 archive
0.0.1 Oct 23, 2018 Go to the documentation of pubspeccheck 0.0.1 Download pubspeccheck 0.0.1 archive
Popularity:
Describes how popular the package is relative to other packages. [more]
0
Health:
Code health derived from static analysis. [more]
100
Maintenance:
Reflects how tidy and up-to-date the package is. [more]
80
Overall:
Weighted score of the above. [more]
46
Learn more about scoring.

We analyzed this package on Feb 4, 2019, and provided a score, details, and suggestions below. Analysis was completed with status completed using:

  • Dart: 2.1.0
  • pana: 0.12.13

Platforms

Detected platforms: Flutter, web, other

No platform restriction found in libraries.

Maintenance suggestions

Maintain an example. (-10 points)

Create a short demo in the example/ directory to show how to use this package.

Common filename patterns include main.dart, example.dart, and pubspeccheck.dart. Packages with multiple examples should provide example/README.md.

For more information see the pub package layout conventions.

Package is pre-v0.1 release. (-10 points)

While nothing is inherently wrong with versions of 0.0.*, it might mean that the author is still experimenting with the general direction of the API.

Dependencies

Package Constraint Resolved Available
Direct dependencies
Dart SDK >=2.0.0 <3.0.0
args ^1.5.0 1.5.1
pub_client ^3.0.0 3.0.2
pub_semver ^1.4.2 1.4.2
pubspec_parse ^0.1.2+2 0.1.4
yaml ^2.1.15 2.1.15
Transitive dependencies
async 2.0.8
charcode 1.1.2
collection 1.14.11
http 0.11.3+17 0.12.0+1
http_parser 3.1.3
json_annotation 1.2.0 2.0.0
meta 1.1.7
path 1.6.2
source_span 1.5.4
string_scanner 1.0.4
term_glyph 1.1.0
typed_data 1.1.6