Skip to content

Instantly share code, notes, and snippets.

@reilg
reilg / publish.sh
Created March 12, 2025 10:31 — forked from shuckster/publish.sh
Publish a new version of an npm package
#!/bin/sh
#
# Publish a new version of an npm package.
#
# - Runs linter, tests
# - Asks if next version is major, minor or patch
# - Calculates the next version from this
# - Checks that the CHANGELOG references the new version
# - Tags/publishes the new version via git/npm