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 🙏

© 2026 – Pkg Stats / Ryan Hefner

@zokugun/bump-n-ship

v0.1.2

Published

Bump your project version, update files, and publish tags or PRs with ease.

Readme

@zokugun/bump-n-ship

License: MIT NPM Version NodeJS Version Modules Ko-fi Liberapay PayPal

Automate version bumping and release workflows. Update manifest files and publish to Git via tags or pull requests based on your project configuration.

Features

  • Interactive prompts: Choose your next version interactively through a simple CLI prompt when not in CI mode.
  • Manual overrides: Set an exact version or specify the increment type directly via command-line flags.
  • Tagging releases: Annotate your release commit with an automatic or custom Git tag.
  • Pull request releases: Branch out and push changes to a dedicated PR branch for review before merging.
  • Template tokens: Supports dynamic strings in commit messages, tag names, and PR titles using variables like {date}, {index}, and {index} properties.
  • Prerelease handling: Easily manage prerelease identifiers and build metadata using customizable templates.
  • NPM hooks: Execute your defined preversion, version, and postversion scripts during the release.

Installation

npm add --save-dev @zokugun/bump-n-ship

Requirements

  • Node.js: v18.20 or higher
  • Modules: ECMAScript Modules (ESM)

Quick Start

Example 1: Basic Version Bumping

Use the bump command to update the version in your package.json and package-lock.json files without creating a Git commit.

Bumping a patch version:

# Update the current version by one patch level (e.g., 1.0.0 -> 1.0.1)
npx bump-n-ship bump --patch

Using an interactive prompt: If you do not specify an increment level, the tool prompts you to select the next version.

# Start the interactive selection process
npx bump-n-ship bump

Dry run mode: Verify what the next version will be without modifying any files.

# Preview the resulting version in the console
npx bump-n-ship bump --patch --dry-run

Example 2: Full Release to Git Tag

The release command automates the entire process: it bumps the version, creates a Git commit, adds a tag, and pushes changes to the remote repository.

Customizing the commit message: You can specify a custom message for the release commit instead of using the default version string.

# Release with a specific commit header
npx bump-n-ship release --patch --commit 'fix: resolve memory leak in parser'

Using a manual version: Set the project to a specific version regardless of the previous state.

# Force the version to 2.0.0 and publish as a tag
npx bump-n-ship release --set-version '2.0.0'

Manually edit files like CHANGELOG.md:

# After the version has been selected, pause to manually edit files like `CHANGELOG.md`
npx bump-n-ship release --all --pause

Example 3: Release via Pull Request

For projects that require code review before merging a release, use the --pr flag. This creates a dedicated release branch instead of tagging the main branch directly.

Creating a pre-release PR:

# Bump to a pre-release version and create a release branch
npx bump-n-ship release --pre --pr

CLI Commands

Four commands are available: bump, release, tag, and get-version.

bump

Updates the project version in configured files without creating Git commits or tags.

npx bump-n-ship bump [options]

Options:

| Flag | Description | | --------------------------------- | --------------------------------------------------------------------------------------------------------- | | -b, --build <version> | Set build metadata | | --ci | Disable interactive prompts; auto-detected in CI environments | | -c, --current-version <version> | Override the current version | | -d, --dry-run | Show what would happen without writing files | | --ignore-scripts | Skip preversion, version npm scripts | | -i, --increment <level> | Specify bump type: major, minor, patch, release, premajor, preminor, prepatch, prerelease | | --major | increment the MAJOR version. | | --minor | increment the MINOR version. | | --patch | increment the PATCH version. | | -p, --pause | Pause before writing files (not supported in CI) | | --pre [label] | Set or increment pre-release label | | -r, --release | Bump from pre-release to full release | | -s, --set-version <version> | Manually set an exact version |

release

Bumps the version, creates a Git commit and tag (or pull request), then pushes.

npx bump-n-ship release [options]

| Flag | Description | | --------------------------------- | --------------------------------------------------------------------------------------------------------- | | -b, --build <version> | Set build metadata | | --ci | Disable interactive prompts; auto-detected in CI environments | | -c, --current-version <version> | Override the current version | | --commit <message> | Custom commit message template | | --confirm | Prompt for confirmation before each step | | --dirty | Continue even with uncommitted changes | | -d, --dry-run | Show what would happen without writing files | | --ignore-scripts | Skip preversion, version, and postversion npm scripts | | -i, --increment <level> | Specify bump type: major, minor, patch, release, premajor, preminor, prepatch, prerelease | | --major | increment the MAJOR version. | | --minor | increment the MINOR version. | | --no-verify | Skip Git hooks | | --patch | increment the PATCH version. | | -p, --pause | Pause before writing files (not supported in CI) | | --pr | Release via a pull request. | | --pre [label] | Set or increment pre-release label | | -r, --release | Bump from pre-release to full release | | -s, --set-version <version> | Manually set an exact version | | --sign | GPG-sign the commit and tag | | --tag <name> | Custom tag name template |

tag

Commits and tags the current version without bumping.

npx bump-n-ship tag [options]

| Flag | Description | | -------------------- | ------------------------------------------------------------- | | --all | Stage all changes instead of only version files | | --ci | Disable interactive prompts; auto-detected in CI environments | | --commit <message> | Custom commit message template | | --confirm | Prompt for confirmation before each step | | --dirty | Continue even with uncommitted changes | | -d, --dry-run | Show what would happen without writing files | | --ignore-scripts | Skip postversion npm scripts | | --no-verify | Skip Git hooks | | -p, --pause | Pause before writing files (not supported in CI) | | --sign | GPG-sign the commit and tag | | --tag <name> | Custom tag name template |

get-version

Prints the current version from package.json.

npx bump-n-ship get-version

No options.

Configuration

The package reads .bumpnshiprc{.json,.yaml,.yml} from the project root.

Example:

bump:
  preRelease: 'beta.{index:1}'

publish:
  remote: origin
  sign: false
  dirty: false
  all: false
  verify: true
  tag:
    name: 'v{version}'
    message: '{version}'
  commit:
    header: 'chore: release {version}'
  pullRequest:
    branch: 'release/{tag}'
    title: 'chore: release {tag}'
    body: '{oldVersion} → {version}'

Template Variables

See Template Variables for available placeholders and where they can be used.

Contributions

Contributions are most welcome. Please:

  • Open issues and feature requests under the repository discussions.
  • Follow the CONTRIBUTING.md.

Donations

Support this project by becoming a financial contributor.

License

Copyright © 2026-present Baptiste Augrain

Licensed under the MIT license.