conventional 0.2.4
conventional: ^0.2.4 copied to clipboard

A light-weight library for working with commits that follow the Conventional Commits specification.

Conventional #

build Coverage Status Pub

A light-weight library for working with commits that follow the Conventional Commits specification.

Features #

  • Commit.parseCommits() for parsing commits from a git --no-pager log --no-decorate command output.
  • hasReleasableCommits() for checking if a list Commit items has releasable commits following the convention.
  • writeChangelog() for automated authoring of CHANGELOGs based on commits that follow the conventional commits spec.
  • lintCommit() for checking whether commit messages follow the conventional commit spec. Useful when used alongside git_hooks.
  • nextVersion() for bumping to a next version based on releasable commits.

Usage #

A simple usage example:

import 'package:conventional/conventional.dart';

main() {
  final List<Commit> commits = Commit.parseCommits(testLog);
  if (hasReleasableCommits(commits)) {
    writeChangelog(
      commits: commits,
      changelogFilePath: 'CHANGELOG.md',
      version: '1.2.0',
      now: DateTime.now(),
    );
  }
}

Feature Requests and Bugs #

Please file feature requests and bugs at the issue tracker. PR's are welcome and appreciated!

Other Solutions #

0
likes
110
pub points
31%
popularity

A light-weight library for working with commits that follow the Conventional Commits specification.

Repository (GitHub)
View/report issues

Documentation

API reference

Uploader

asartalo@gmail.com

License

MIT (LICENSE)

Dependencies

equatable, petitparser, pub_semver

More

Packages that depend on conventional