1
0
Fork 0

🔧 Updated (re)configure script

This commit is contained in:
Joost De Cock 2019-05-02 21:17:18 +02:00
parent 116b94b0f2
commit 8e30902d69
3 changed files with 19 additions and 11 deletions

View file

@ -125,9 +125,11 @@ function scripts(pkg, config, type) {
}
if (typeof config.scripts[pkg] !== "undefined") {
for (let key of Object.keys(config.scripts[pkg])) {
runScripts[key] = Mustache.render(config.scripts[pkg][key], {
name: pkg
});
if (config.scripts[pkg][key] === "!") delete runScripts[key];
else
runScripts[key] = Mustache.render(config.scripts[pkg][key], {
name: pkg
});
}
}
@ -192,6 +194,9 @@ function packageConfig(pkg, config) {
...pkgConf,
...config.exceptions.packageJson[pkg]
};
for (let key of Object.keys(config.exceptions.packageJson[pkg])) {
if (config.exceptions.packageJson[pkg][key] === "!") delete pkgConf[key];
}
}
return pkgConf;