install-pkg-lock
Version:
Only npm install if package-lock.json has been modified
27 lines (21 loc) • 689 B
JavaScript
const { program } = require("commander");
const watcher = require("../lib/main");
program
.option(
"--install-command [command]",
"The command to run when dependencies need to be installed/updated"
)
.option(
"--hash-filename [filename]",
"Filename where hash of dependencies will be written to"
)
.option("--lock-filename [lock_filename]", "Filename of package lock")
.option("--hash-only", "Only update the hash");
program.parse(process.argv);
watcher({
installCommand: program.installCommand,
hashFilename: program.hashFilename,
lockFilename: program.lockFilename,
isHashOnly: program.hashOnly,
});