publish-please
Version:
Safe and highly functional replacement for `npm publish`.
16 lines (13 loc) • 377 B
JavaScript
;
const fileExists = require('fs').existsSync;
const pathJoin = require('path').join;
(function preInstall(currentDir) {
const jsFile = pathJoin(
currentDir || __dirname,
'prevent-global-install.js'
);
if (fileExists(jsFile)) {
const preventGlobalInstall = require(jsFile);
preventGlobalInstall();
}
})(__dirname);