Skip to content

VincentHardouin/npm-bump

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

56 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

NPM-BUMP

npm-bump is a Bash Script for bump npm version.

It exists because tasks of update packages are frequent and boring. This script bump versions of packages that have no tests issues.

npm-bump-demo.mp4

Installation

On OS X, you can install npm-bump via Homebrew:

brew tap vincenthardouin/npm-bump
brew install npm-bump

With make

make install

Classic method

  1. Clone repository
git clone git@github.com:VincentHardouin/npm-bump.git
  1. Go in directory
cd npm-bump
  1. Add permission
chmod 777 npm-bump
  1. Create symlink
ln -sf ${PWD}/npm-bump /usr/local/bin

Usage

On directory who have package.json and package-lock.json Run :

npm-bump

And wait ⌛ with ☕

Optional arguments

  -h, --help                show this help message and exit
  -c, --command             run custom command after npm install and rollback install when given command exit code is > 0, not works with no-test option
  -e, --exclude             exclude package name seprated by a comma (e.g -e lodash,mocha)
  -m, --markdown            display updated packages in markdown table
  -nt, --no-test            does not run test command when update package
  -sbs, --step-by-step      test bump version step by step"

Features

  • Script available globally
  • Verify outdated package
  • Use npm install instead of npm update
  • Try to install latest version of each package, or try step-by-step with --step-by-step option
  • Run npm test after each npm install to verify exit code or given custom command with --command option
  • Create bump commit for each package
  • Show updated packages and packages not updated at the end