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

mcfly-semantic-release

v1.3.0

Published

A cli tool to bump version and publish to github

Downloads

25

Readme

mcfly-semantic-release

NPM version Downloads
Build Status Coverage percentage
Dependency Status Dependency Dev Status

NPM

Installation

npm i --save-dev mcfly-semantic-release

Usage

In your package.json

"scripts": {
  "release": "mcfly-semantic-release"
}

Running release will do the following:

  • Bumps version. By default, this will publish a patch version, if you want to control the semver option you can pass an optional type --type argument. The prerelease versions will be in the format of 2.3.2-4. valid types are: 'major', 'minor', 'patch', 'premajor', 'preminor', 'prepatch', 'prerelease'
  • Updates version in files: by default it will only update the root level package.json. Optionnaly use --file to specify file paths or files patterns (globs) that can have their version updated as well. Files can be package.json files or config.xml files
  • Commit the changed files with a standard commit message. Default message is chore(app): Version <version number>. Use --production to suffix the commit message with the work production (can be later used in CI)
  • Generates changlog based on Angular standard commit messages.
  • Generate a tag with the version number.
  • Generates a github release with the version number.
"scripts": {
  "release": "mcfly-semantic-release.js --files ./package.json ./bower.json ./config.xml ./projects/**/package.json"
}

NOTE
the path for the --files option is relative to your current root directory

Then, to publish a new version execute the following command:

npm run release

Example :

npm run release -- --type=minor

NOTE
The double -- is necessary, this is how npm script propagates its arguments

Alternate github authentication methods

By default mcfly-semantic-release uses basic username & password auth to communicate with github. Whem it runs, you will be prompted for your github username and password before the release will run. If your username for github is available in your git config, mcfly-semantic-release will find it and not prompt you to enter it.

As an alternative to basic auth, you can provide an oauth token (see github oauth). To use a token, make sure it is valid and has the correct scopes for the repo and then pass it as $GITHUB_TOKEN. Then, when prompted for your password, just leave it blank and hit enter and the token will be used for the authentication!

~/dev/mcfly-io/mcfly-semantic-release $> GITHUB_TOKEN=<oauth_token> npm run release

> [email protected] release /Users/marty/dev/mcfly-io/mcfly-semantic-release
> node bin/mcfly-semantic-release.js

Hello [email protected], let's publish a new version...
? Please enter your GitHub password (leave blank to use $GITHUB_TOKEN)
Github authentication...
Generating changelog...
Bumping files...
Committing version...
Publishing version...
Release v1.0.16 successfully published!