pana 0.7.3+1

  • README.md
  • CHANGELOG.md
  • Installing
  • Versions
  • 84

Build Status

A library for analyzing Dart packages.

  • Validates the code using Dart Analyzer.
  • Checks code formatting.
  • Checks for outdated dependencies.
  • Infers supported platforms: Flutter, web, and/or server.

Used by the Dart Package site.

Use as an executable

Installation

> pub global activate pana

Usage

Usage: pana [<options>] <package name> [<package version>]

Options:
  -j, --json    Output log items as JSON.

0.7.3+1

  • Allow more versions of package:args.

0.7.3

  • Added pana as an executable. Enables pub global activate pana.

  • Improved license detection: commented license files are now recognized.

0.7.2

  • Handle more critical exceptions and report them with more details.

  • The Suggestion.bug constructor had a breaking change – a required argument was added, but this is not intended for invocation by end-users.

0.7.1

  • Add SuggestionLevel.bug and use it to record fatal errors with the tool.

0.7.0+1

  • Fixed issue where analyzer and/or formatter were run on directories with no Dart files.

0.7.0

  • Breaking changes

    • Summary.sdkVersion is now a Version instead of String.

    • new PackageAnalyzer(...) now takes a DartSdk instance instead of a String.

  • static Future<PackageAnalyzer> create(...) was added to PackageAnalyzer.

  • Added logger optional argument to PackageAnalyzer.inspectPackage.

0.6.2

  • Allow platform classification for a small class of analysis errors.

0.6.1

  • Don't count the absence of an analysis_options.yaml file against a package.

0.6.0

  • Breaking changes

    • Removed ToolProblem class.
    • Removed Summary.toolProblems, in favor of Summary.suggestions.
  • Detect and store maintenance-related data in summary.

    • Scoring of tool problems moved from Fitness to Maintenance.
  • Provide human-readable feedback and instructions on some of the issues we find during the analysis.

0.5.1

  • Use a consistent 2 minute timeout for all processes.

  • Classify platform as nowhere when part of analysis fails.

0.5.0

  • Breaking changes

    • License renamed to LicenseFile
    • Summary.license -> licenses: we'll return multiple licenses
    • Removed LicenseNames.missing: empty List will indicate no license file
  • Greatly expanded and improved license detection.

0.4.0

  • Breaking changes

    • Renamed AnalyzerIssue -> ToolProblem

      • Renamed Summary.issues -> toolProblems
      • Renamed AnalyzerIssue.scope -> tool
      • Renamed AnalyzerScopes -> ToolNames
    • Renamed AnalyzerOutput -> CodeProblem

      • Renamed Summary.analyzerItems and DartFileSummary.analyzerItems -> codeProblems
    • Refactored CodeProblem (previously AnalyzerOutput):

      • Split up type, new fields: severity, errorType, errorCode
      • Renamed error to description
    • Refactored Fitness:

      • Renamed total -> magnitude
      • Removed value, using shortcoming instead (value = magnitude - shortcoming;)
    • Refactored PubSummary, renamed to PkgResolution

      • Moved pubspec -> Summary
      • Moved pkgVersion -> Pubspec.version
      • Moved authors -> Pubspec.authors
      • Merged packageVersions and availableVersions into dependencies
      • Renamed Summary.pubSummary -> pkgResolution
    • Refactored platform:

      • Renamed PlatformFlags -> PlatformNames
      • Removed most of the platform-related classes, using DartPlatform instead

0.3.0

  • Removed PlatformSummary.package in favor of PlatformSummary.pubspec of (new) type PubspecPlatform.

  • Renamed KnownPlatforms to PlatformFlags. Also:

    • Removed mirrors, browser and standalone.
    • Renamed native to dartExtension.
  • PlatformInfo

    • Now store dart:* references directly in uses.
    • worksInStandalone renamed to worksOnServer.
    • Other .worksIn* renamed to worksOn*.
    • Added String get description which returns a simple String description of the supported platforms. Examples: everywhere, flutter, server, web, conflict.
    • Removed angular as a value in uses.

0.2.4

  • Detect native extensions.

  • Detect licenses.

0.2.3

  • Lot's of stability improvements.

  • Improvements to error handling.

0.2.2

  • Lot's of cleanup to JSON output.

  • Improved stability.

  • Platform detection basics.

0.2.1

  • Added support for flutter packages.

  • Expanded analysis to include transitive dependencies.

  • Added scoring library.

  • Moved the repo to dart-lang.

0.2.0

  • A lot of tweaks. Still under heavy development.

0.0.1

  • Initial version.

1. Depend on it

Add this to your package's pubspec.yaml file:


dependencies:
  pana: "^0.7.3+1"

2. Install it

You can install packages from the command line:

with pub:


$ pub get

with Flutter:


$ flutter packages get

Alternatively, your editor might support pub get or packages get. Check the docs for your editor to learn more.

3. Import it

Now in your Dart code, you can use:


import 'package:pana/pana.dart';
        
Version Uploaded Documentation Archive
0.7.3+1 Dec 6, 2017 Go to the documentation of pana 0.7.3+1 Download pana 0.7.3+1 archive
0.7.3 Dec 5, 2017 Go to the documentation of pana 0.7.3 Download pana 0.7.3 archive
0.7.2 Nov 29, 2017 Go to the documentation of pana 0.7.2 Download pana 0.7.2 archive
0.7.1 Nov 27, 2017 Go to the documentation of pana 0.7.1 Download pana 0.7.1 archive
0.7.0+1 Nov 27, 2017 Go to the documentation of pana 0.7.0+1 Download pana 0.7.0+1 archive
0.7.0 Nov 22, 2017 Go to the documentation of pana 0.7.0 Download pana 0.7.0 archive
0.6.2 Nov 17, 2017 Go to the documentation of pana 0.6.2 Download pana 0.6.2 archive
0.6.1 Nov 16, 2017 Go to the documentation of pana 0.6.1 Download pana 0.6.1 archive
0.6.0 Nov 15, 2017 Go to the documentation of pana 0.6.0 Download pana 0.6.0 archive
0.5.1 Oct 28, 2017 Go to the documentation of pana 0.5.1 Download pana 0.5.1 archive

All 20 versions...

Analysis

This feature is new.
We welcome feedback.

We analyzed this package, and provided a score, details, and suggestions below.

  • completed on Dec 6, 2017
  • Dart: 2.0.0-dev.8.0
  • pana: 0.7.3+1

Scores

Popularity:
Describes how popular the package is relative to other packages. [more]
68
Health:
Code health derived from static analysis. [more]
100
Maintenance:
Reflects how tidy and up-to-date the package is. [more]
99
Overall score:
Weighted score of the above. [more]
84

Platforms

Detected platforms: Flutter, server

all of the above

Dependencies

Package Constraint Resolved Available
Direct dependencies
analyzer ^0.30.0 0.30.0+4 0.31.0-alpha.2
args >=0.13.7 <2.0.0 1.2.0
async >=1.13.3 <3.0.0 2.0.1
cli_util ^0.1.1 0.1.2+1
http >=0.11.3 <0.12.0 0.11.3+16
io ^0.3.0 0.3.1
json_annotation ^0.2.0 0.2.1
logging ^0.11.3+1 0.11.3+1
path ^1.4.1 1.5.1
pool ^1.3.0 1.3.3
pub_semver ^1.3.2 1.3.2
quiver >=0.24.0 <0.27.0 0.26.2
yaml ^2.1.12 2.1.13
Transitive dependencies
charcode 1.1.1
collection 1.14.3
convert 2.0.1
crypto 2.0.2+1
csslib 0.14.1
front_end 0.1.0-alpha.4.1 0.1.0-alpha.7
glob 1.1.5
html 0.13.2
http_parser 3.1.1
isolate 1.1.0
kernel 0.3.0-alpha.1.1 0.3.0-alpha.4
matcher 0.12.1+4
meta 1.1.2
package_config 1.0.3
plugin 0.2.0+2
source_span 1.4.0
stack_trace 1.9.1
string_scanner 1.0.2
typed_data 1.1.5
utf 0.9.0+3
watcher 0.9.7+4
Dev dependencies
build ^0.11.0
build_runner ^0.6.0
json_serializable ^0.2.4
source_gen ^0.7.2
test ^0.12.0
test_process ^1.0.1