This small utility helps to change version in your project
- In your terminal run command:
npm install @pixelygroup/version-x --save-dev
- Add into scripts section in package.json
"scripts": {
...
"version-x": "version-x",
"version-major": "version-x -m",
"version-minor": "version-x -i",
"version-patch": "version-x -p",
...
},
- This will allow you to run them as:
npm run version-x -- -x 1.1.1-exact-version
OR
npm run version-patch
Usage: -b 1.1.1 <version> / -m <major> / -i <minor> / -p <patch>.
In case of passing multiple options,
the conditions will be checked and applied
in the same order (left > right)
Options:
--help Show help [boolean]
--version Show version number [boolean]
-x, --exact requires version in format 1.1.1 or 1.1.1-beta, etc. [string]
-m, --major Bumps a version on X position X.1.1 [boolean]
-i, --minor Bumps a version on X position 1.X.1 [boolean]
-p, --patch Bumps a version on X position 1.1.X [boolean]
-t, --tag Creates and pushes git tag [boolean]
- Download the repository.
- Enter the directory and run
npm install -g .
In your terminal run command:
npm install -g @pixelygroup/version-x
npm uninstall -g @pixelygroup/version-x