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

ac-semantic-release

v0.4.3

Published

Lightweight semantic release management

Downloads

518

Readme

AC Semantic Release

AdmiralCloud Semantic Release Manager makes sure your commits and release follow semantic versioning guidelines.

Why use this package

First of all, it is always a good idea to use semantic versioning for your repositories and make the process as easy as possible for all your developers and contributors.

It has few dependencies and is actively maintained as we use it in our AdmiralCloud release management.

Usage

Install using yarn add ac-semantic-release

You can then add the commands for committing and releasing into your package.json or into a Makefile.

Example Makefile

commit:
	@node ./node_modules/ac-semantic-release/lib/commit.js

release:
	@node ./node_modules/ac-semantic-release/lib/release.js

test-release:
	DEBUGMODE=true node ./node_modules/ac-semantic-release/lib/release.js  

Committing

Add the files you want to commit using CLI command or any GUI (e.g. Source Tree). Then instead of "git commit -m SOME MESSAGE" you simply type "make commit".

You will then be guided through some questings regarding the type of your commit, sections etc. After answering those, you will see a preview of your commit message and can then confirm that message.

That's it.

Releasing a new version/new tag

In order to create a new release use "make release" (if you have created the Makefile like mentioned above).

This process will

  • fetch all commits since the latest tag/release
  • create a meaningfuk changelog from the commit messages
  • check if a release is necessary
  • update the package.json with the new version number/tag
  • commit the changelog and the package.json
  • create the new tag
  • push the commit and the tag

PRO TIP No 1
You can check what the release would look like using environment variable DEBUGMODE:

export DEBUGMODE=true
@node ./node_modules/ac-semantic-release/lib/release.js

PRO TIP No 2 In case commit messags turn out to be incorrect, you might want to use a fixed version (instead of auto semantic versioning). Now this module supports that function by exporting a fixed version, e.g. export FIXEDVERSION=1.0.0.

Customizing

It is highly recommended that you create a configuration file in your actual repository. Please name it ".acsemver.js" and make sure it is also part of your source control (in other words: commit it!)

The local configuration file should at least contain the following properties

module.exports = {
  repository: {
    url: 'https://github.com/ACCOUNT/REPO'
  },
  jira: {
    url: 'https://MY-INSTANCE.atlassian.net' // This is optional
  }
  changelogFile: __dirname + '/CHANGELOG.md',
  scopes: [
    {name: 'Misc' },
    ... // optional more
  ]
}

Please take a look at the config file in this repo to see all config options. You can change types, templates (EJS), section and questions (during commit).

Thanks

We have been using semantic-release package for a long time but created our own release management because we needed more control over dependencies and did not need all the functionalities. Still, this package is highly inspired by the great work of the semantic-release team.

Links

License

MIT License Copyright © 2009-present, AdmiralCloud AG, Mark Poepping