3.0.1 • Published 4 years ago

semantic-release-example v3.0.1

Weekly downloads
3
License
MIT
Repository
github
Last release
4 years ago

semantic-release-example

Greenkeeper badge Build Status codecov npm GitHub release license semantic-release

Introduction

This (very simple) package hopefully helps to illustrate how to implement the semantic-release package in an existing NPM package.

Implementation Notes

Use the semantic-release-cli package to get setup.

alt-text

It uses the Angular commit message convention which is also the default commit message convention for semantic-release.

It uses commitlint for (you guessed it) commit linting, and husky for Git hooks (specifically, the commit-msg hook.

The npm run semantic-commit script triggers a helpful commit message CLI (the commitlint cli package)

A new release is cut when the master branch Travis build successfully completes and there's a formatted commit message that should trigger a semantic version change. A Git tag is created, a GitHub release is created, and the NPM package is published with the appropriate semantic version update.

Invalid Commit Message Failure

alt-text

Commit Message CLI

Specify a type

alt-text

Specify a scope

alt-text

Specify a subject

alt-text

Full commit message after the CLI exits successfully

alt-text

3.0.1

4 years ago

3.0.0

6 years ago

2.0.0

6 years ago

1.1.6

6 years ago

1.1.5

6 years ago

1.1.4

6 years ago

0.0.0

6 years ago

1.1.3

6 years ago

1.1.2

6 years ago

1.1.1

6 years ago

1.1.0

6 years ago

1.0.0

6 years ago