Socket
Socket
Sign inDemoInstall

patch-version

Package Overview
Dependencies
Maintainers
1
Versions
4
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

patch-version

Patch version control tag version to package.json when deploy to npm on CI.


Version published
Weekly downloads
24
decreased by-25%
Maintainers
1
Weekly downloads
 
Created
Source

patch-version Build Status

Patch git tag version to package.json before publish to npm.

Usage

  1. Install patch-version from npm.
  2. Stick your package.json to one version. My suggestion is 0.0.1, as this package does.
  3. Add patch-version command to deployment hook in your CI configuration file.
  4. When you want to publish a new version to npm, create a tag with a valid semver, push it to trigger CI build and deployment. The tag version will be patched to package.json before publish to npm.

Supported CI

  • Travis
  • GitLab
  • AppVeyor

Example

Here is the example configuration in .travis.yml for Travis CI:

before_deploy:
  - ./node_modules/.bin/patch-version

deploy:
  provider: npm
  email: "my@email"
  api_key:
    secure: "secure-key"

License

MIT License.

Keywords

FAQs

Package last updated on 22 Nov 2015

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc