jsmv v2.1.1
jsmv
replace requires across your codebase
installation
npm install -g jsmv
why
so you can do jsmv old-module.js new-module.js to replace all requires for
old-module.js to new-module.js. it will even take care of making sure all
of your relative paths are correct!
or even jsmv modules/my-request.js request to replace any require for
modules/my-request.js with the actual request module.
usage
jsmv [options] [from] [to]
options are:
--from, -f <modulename>Find files that require<modulename>--to, -t <modulename>Rename all matches to<modulename>--require, -R <name>Look fornamevs.require--dir, -d <dir>Search javascript files in<dir>(default CWD)--file, -F <file>Only search<file>for relevant modules--recurse, -rRecurse into subdirectories--forceIn the event of a deep-require, replace the module anyway--forceFullFor deep-requires, replace the whole require with[to]--version, -vPrint current version--help, -hThis thing
if --from and --to are not explicitly declared, the first two non-flag
command line options will be used in their place respectively.
license
MIT
11 years ago
11 years ago
11 years ago
11 years ago
11 years ago
11 years ago
11 years ago
12 years ago
12 years ago
12 years ago
12 years ago
12 years ago
12 years ago
12 years ago
12 years ago
12 years ago
12 years ago
12 years ago
12 years ago
12 years ago
12 years ago