npm-submodules
Version:
Simple way to manage typescipt and angular2 submodules from one repository
14 lines (13 loc) • 490 B
JavaScript
Object.defineProperty(exports, "__esModule", { value: true });
const execa = require('execa');
function npmDistTag({ yarn, cmd, module, version, tag = '' }) {
// const npm = yarn ? 'yarn' : 'npm';
const pkg = cmd === 'add' ? `${module}@${version}` : module;
return execa.shell(['npm', 'dist-tag', cmd, pkg, tag].join(' '))
.then(res => {
console.log(`Package ${module}`);
console.log(res.stdout);
});
}
exports.npmDistTag = npmDistTag;
;