@wmde/lib-version-check
v0.1.1-alpha.2
Published
A small utility to check library versions against a remote copy
Downloads
954
Readme
Lib Version Check
A small utility to check remote library versions against a local dependency entry.
Usage
Install
npm i lib-version-check
Add remote library urls to your
package.json
{ // ... "config": { "remoteVersion": { // <package-name>: <remote> "vue": "https://raw.githubusercontent.com/wikimedia/mediawiki/master/resources/lib/vue/vue.common.prod.js", } } }
Run in a directory that contains your
package.json
lib-version-check
Add a script to your
package.json
, to run anywhere within your project{ // ... "scripts": { "check-versions": "lib-version-check" } }
Environment Variables
Interpolate environment variables to a specified remote url
{ // ... "config": { "remoteVersion": { // <package-name>: <remote> "vue": "https://raw.githubusercontent.com/wikimedia/mediawiki/#{SOME_BRANCH}/resources/lib/vue/vue.common.prod.js", } } }
Define the environment variable and run the check
SOME_BRANCH=main lib-version-check