strapi/scripts/setup.js

21 lines
885 B
JavaScript
Raw Normal View History

2017-03-14 12:25:39 +01:00
const shell = require('shelljs');
// Remove existing binary.
shell.rm('-f', '/usr/local/bin/strapi.js');
shell.echo('Linking Strapi CLI...');
2017-07-17 16:48:09 +02:00
shell.cd('packages/strapi-utils');
shell.exec('npm link');
2017-07-17 16:48:09 +02:00
shell.cd('../strapi-generate');
shell.exec('npm install ../strapi-utils && npm link');
2017-07-17 16:48:09 +02:00
shell.cd('../strapi-admin');
shell.exec('npm install ../strapi-utils && npm link');
2017-07-17 16:48:09 +02:00
shell.cd('../strapi-generate-admin');
shell.exec('npm install ../strapi-admin && npm link');
2017-07-17 16:48:09 +02:00
shell.cd('../strapi-generate-new');
shell.exec('npm install ../strapi-utils && npm link');
2017-07-17 16:48:09 +02:00
shell.cd('../strapi-mongoose');
shell.exec('npm install ../strapi-utils && npm link');
2017-07-17 16:48:09 +02:00
shell.cd('../strapi');
shell.exec('npm install ../strapi-generate ../strapi-generate-admin ../strapi-generate-api ../strapi-generate-new ../strapi-generate-policy ../strapi-generate-service ../strapi-mongoose ../strapi-utils && npm link');