JSPM

  • Created
  • Published
  • Downloads 336422
  • Score
    100M100P100Q182084F
  • License MIT

Generate a changelog from git metadata

Package Exports

  • conventional-changelog-cli/cli
  • conventional-changelog-cli/cli.js

This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (conventional-changelog-cli) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.

Readme

conventional-changelog-cli NPM version Build Status Dependency Status Coverage percentage

Generate a changelog from git metadata

Quick start

$ npm install -g conventional-changelog-cli
$ cd my-project
$ conventional-changelog -p angular -i CHANGELOG.md -w

This will not overwrite any previous changelog. The above generates a changelog based on commits since the last semver tag that match the pattern of a "Feature", "Fix", "Performance Improvement" or "Breaking Changes".

If you first time use this tool and want to generate all previous changelog, you could do

$ conventional-changelog -p angular -i CHANGELOG.md -w -r 0

This will overwrite any previous changelog if exist.

All available command line parameters can be listed using CLI : conventional-changelog --help.

Hint: You can alias your command or add it to your package.json. EG: "changelog": "conventional-changelog -p angular -i CHANGELOG.md -w -r 0".

  1. Make changes
  2. Commit those changes
  3. Make sure Travis turns green
  4. Bump version in package.json
  5. conventionalChangelog
  6. Commit package.json and CHANGELOG.md files
  7. Tag
  8. Push

The reason why you should commit and tag after conventionalChangelog is that the CHANGELOG should be included in the new release, hence gitRawCommitsOpts.from defaults to the latest semver tag.

Please use this gist to make a release or change it to your needs.

Example output

Why

  • Used by AngularJS and related projects.
  • Ignoring reverted commits, templating with handlebars.js and links to references, etc. Open an issue if you want more reasonable features.
  • Intelligently setup defaults but yet fully configurable with presets of popular projects.
  • Everything internally or externally is pluggable.
  • A lot of tests and actively maintained.

License

MIT © Steve Mao