Package Exports
- svecchiator
- svecchiator/dist/index.js
This package does not declare an exports field, so the exports above have been automatically detected and optimized by JSPM instead. If any package subpath is missing, it is recommended to post an issue to the original package (svecchiator) to support the "exports" field. If that is not possible, create a JSPM override to customize the exports field for this package.
Readme
svecchiator
An npm module to brutally update a Node.js project's dependencies
The name
A little explaination of the name svecchiator:
In Italian "svecchiare" means to remove the old parts from something or to renew something. This module will remove the old dependencies, replacing them with the ones with the latest versions.
How does it work
Under the hood, svecchiator reads the package.json file and manually calls the npm install and npm uninstall commands to update the dependencies.
Install
To install svecchiator as a local module:
$ npm install svecchiatorTo install svecchiator as a global module:
$ npm install -g svecchiatorUsage (local module)
Upgrade everything
Simple:
import { svecchia } from 'svecchiator';
async function main() {
await svecchia();
}
main();With custom configuration:
import { svecchia } from 'svecchiator';
async function main() {
await svecchia({
path: '../my-project',
onlyDevDeps: true,
cleanCache: true,
exclude: ['dree', 'eslint']
});
}
main();Usage (global module)
Simple
$ svecchiaThis will uninstall and install again all the deps and dev deps of the current dir project.
Only dev deps and with another project dir
$ svecchia --dev --source ./my-projectThis will uninstall and install again only the dev deps of the project in ./my-project.
This will exclude the packages dree and eslint
$ svecchia -e eslint -e dreeMore help
This will show the help of the command.
$ svecchiator --helpAPI
Online documentation
The documentation generated with TypeDoc is available in this site. There is also a more specific version for development in this site.
scan
Syntax:
svecchiator.svecchia(options)
Description:
A function that given some options, upgrades the dependencies of the package.json file. It works by running the command to uninstall and install them again. Note: the function is async.
Options parameters:
- path: Default value:
.. The path of the folder containing the package.json file. - onlyDevDeps: Default value:
false. If true, only the devDependencies will be updated. - onlyProdDeps: Default value:
false. If true, only the dependencies will be updated. - cleanCache: Default value:
false. If true, the npm cache will be cleaned before updating the dependencies. - exclude: Default value:
[]. The list of dependencies to exclude from the update.