Coder Social home page Coder Social logo

version-changelog's Introduction

Version Changelog CircleCI

Add a version & URL to your CHANGELOG.md.

Goes great with changelog-verify. Add this to your package.json:

{
  "scripts": {
    "version": "version-changelog CHANGELOG.md && changelog-verify CHANGELOG.md && git add CHANGELOG.md"
  }
}

Now whenever you execute npm version (or np), your CHANGELOG.md will be given the correct version info, checked for validity (did you forget to add changelog notes?) then added to the release commit.

Usage

Given the following ./CHANGELOG.md

# Changelog

## [Unreleased][]

- These aren’t the droids you’re looking for

## [1.0.0][] - 2016-10-11

- Reticulated the splines

And package.json

{
  "version": "2.0.0"
}

Executing the versioning script

version-changelog ./CHANGELOG.md

Will return success (0), and update CHANGELOG.md to:

# Changelog

## [Unreleased][]

## [2.0.0][] - <today's date>

- These aren’t the droids you’re looking for

## [1.0.0][] - 2016-10-11

- Reticulated the splines

[Unreleased]: <GitHub URL>/compare/v2.0.0...HEAD
[2.0.0]: <GitHub URL>/compare/v1.0.0...v2.0.0
[1.0.0]: <GitHub URL>/tree/v1.0.0

See the tests for more usage examples.

Changelog format

This tool assumes a particular format for your changelog, keeping in style with http://keepachangelog.com:

<some intro text>
## [Unreleased][]
<optional unreleased notes>
## [<version number>][]
<required release notes>

Where <version number> is the more recently previous release of this module.

Options

The cli takes a single optional parameter: the changelog filename:

changelog-verify [filename]

filename can be a path relative to the current working directory, or an absolute path.

version-changelog's People

Contributors

jesstelford avatar jsaguilar avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.