https://github.com/qrac/npm-replace-versions
Update and unify the version of all package.json in the project.
https://github.com/qrac/npm-replace-versions
npm npm-scripts package-json replace update vesions
Last synced: 7 months ago
JSON representation
Update and unify the version of all package.json in the project.
- Host: GitHub
- URL: https://github.com/qrac/npm-replace-versions
- Owner: qrac
- License: mit
- Created: 2023-07-31T23:57:08.000Z (about 2 years ago)
- Default Branch: main
- Last Pushed: 2024-01-02T00:21:11.000Z (almost 2 years ago)
- Last Synced: 2025-02-26T07:47:10.160Z (7 months ago)
- Topics: npm, npm-scripts, package-json, replace, update, vesions
- Language: TypeScript
- Homepage:
- Size: 27.3 KB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# npm-replace-versions
Update and unify the version of all package.json in the project.
## Installation
Install globally:
```sh
$ npm install -g npm-replace-versions
```Or run with [npx](https://docs.npmjs.com/cli/v7/commands/npx):
```sh
$ npx npm-replace-versions
```## Usage
```sh
$ rev✔ Which is the tag of the release? › Major
✔ Major version: … 0.1.1/package.json 0.1.0 -> 0.1.1
✔ Start overwriting?? › Yes
✔ Done
``````sh
# shortcut
$ rev 0.1.1/package.json 0.1.0 -> 0.1.1
✔ Start overwriting? › Yes
✔ Done
```## Options
| option | default | detail |
| ---------- | ----------------- | ----------------------------------------------------- |
| `--root` | `process.cwd()` | Change where to start looking |
| `--files` | `**/package.json` | Glob target file |
| `--ignore` | `node_modules` | Glob ignore file |
| `--deps` | `undefined` | Replace dependencies (ex: `--deps packageA,packageB`) |## License
- MIT
## Credit
- Author: [Qrac](https://qrac.jp)
- Organization: [QRANOKO](https://qranoko.jp)