npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2024 – Pkg Stats / Ryan Hefner

manual-git-changelog

v1.0.2

Published

A simple tool for appending to a changelog based on git commits and tags.

Downloads

15,549

Readme

Manual Git Changelog

Build status Coverage Status Mutation testing badge npm version

A simple tool for appending to a changelog based on git commits and tags.

This is an alternative to tools such as conventional-changelog for projects that don't follow a specific commit convention, but wanting to automate your CHANGELOG.md generation upon each release.

This tool does this by automating the creation of CHANGELOG.md as much as possible, but allowing you to manually polish the file before committing.

This tool assumes that you use semantic versioned git tags (like v1.2.3 and v2.0.1).

Some examples of changelogs that were generated with this tool:

  • https://github.com/comunica/comunica/blob/master/CHANGELOG.md
  • https://github.com/rubensworks/rdf-terms.js/blob/master/CHANGELOG.md

Installation

It is advised to install this tool as a dev dependency:

$ yarn add --dev manual-git-changelog

Usage

After installing, the manual-git-changelog script will become available. It can be used to do three things:

  1. Initialize a new CHANGELOG.md file
  2. Add the changelog for an update while npm version is running.
  3. Manually add the changelog for a particular version to CHANGELOG.md.

These usages will be explained hereafter.

Initialize

By running manual-git-changelog init, you can create a new CHANGELOG.md file based on your current version and git commits.

This command will fail when CHANGELOG.md already exists.

Automatic version appending

If you like more automation in your release process, then you can hook this tool into npm version.

You can do this by adding the following script to your package.json file:

{
  "scripts": {
    "version": "manual-git-changelog onversion"
  }
}

This will make it so that each time you call npm version, the changelog will automatically be updated to the new version.

Note that this will temporarily pause the process to allow you to manually polish the changelog file, to allow you to categorize the commits. This pausing happens when the following is printed to the console

Manually edit CHANGELOG.md, press any key to finalize...

Once you have edited CHANGELOG.md, and are satisfied with its structure, go back to your console, press any key to continue. The tool will automatically stage CHANGELOG.md so that it becomes part of the version bump commit as done by npm version.

Manual version appending

As an alternative to automatic changelog updates during npm version, you can manually trigger a version log to be added to be added to your changelog. You can call the command, with a certain version to set as new version (ex: v1.2.3) as follows:

$ manual-git-changelog v1.2.3

The previous available version (for example v1.2.2) will be automatically detected from the git tags. As such, this script assumes that v1.2.3 has not been tagged yet.

If this version would already be tagged, then this script also allows you to define a custom version range that does not try to infer the previous version from the git tags:

$ manual-git-changelog v1.2.2 v1.2.3

License

This software is written by Ruben Taelman.

This code is released under the MIT license.