mirror of
https://github.com/strapi/strapi.git
synced 2025-11-16 10:07:55 +00:00
Merge branch 'master' into array
This commit is contained in:
commit
3d2f611af2
@ -5,7 +5,7 @@ const _ = require('lodash');
|
|||||||
shell.echo('');
|
shell.echo('');
|
||||||
shell.echo('🕓 The setup process can take few minutes.');
|
shell.echo('🕓 The setup process can take few minutes.');
|
||||||
shell.echo('');
|
shell.echo('');
|
||||||
shell.echo(`🔸 Administration Panel`);
|
shell.echo('🔸 Administration Panel');
|
||||||
shell.echo('📦 Installing packages...');
|
shell.echo('📦 Installing packages...');
|
||||||
|
|
||||||
const pwd = shell.pwd();
|
const pwd = shell.pwd();
|
||||||
@ -19,28 +19,28 @@ shell.rm('-rf', path.resolve(appPath, 'package-lock.json'));
|
|||||||
shell.rm('-rf', path.resolve(appPath, 'admin', 'package-lock.json'));
|
shell.rm('-rf', path.resolve(appPath, 'admin', 'package-lock.json'));
|
||||||
|
|
||||||
// Install the project dependencies.
|
// Install the project dependencies.
|
||||||
shell.exec(`cd ${appPath} && npm install --ignore-scripts`, {
|
shell.exec(`cd "${appPath}" && npm install --ignore-scripts`, {
|
||||||
silent
|
silent
|
||||||
});
|
});
|
||||||
|
|
||||||
// Install the administration dependencies.
|
// Install the administration dependencies.
|
||||||
shell.exec(`cd ${path.resolve(appPath, 'admin')} && npm install`, {
|
shell.exec(`cd "${path.resolve(appPath, 'admin')}" && npm install`, {
|
||||||
silent
|
silent
|
||||||
});
|
});
|
||||||
|
|
||||||
if (isDevelopmentMode) {
|
if (isDevelopmentMode) {
|
||||||
shell.exec(`cd ${path.resolve(appPath, 'admin')} && npm link strapi-helper-plugin && npm link strapi-utils`, {
|
shell.exec(`cd "${path.resolve(appPath, 'admin')}" && npm link strapi-helper-plugin && npm link strapi-utils`, {
|
||||||
silent
|
silent
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
shell.exec(`cd ${path.resolve(appPath, 'admin', 'node_modules', 'strapi-helper-plugin')} && npm install`, {
|
shell.exec(`cd "${path.resolve(appPath, 'admin', 'node_modules', 'strapi-helper-plugin')}" && npm install`, {
|
||||||
silent
|
silent
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
shell.echo('🏗 Building...');
|
shell.echo('🏗 Building...');
|
||||||
|
|
||||||
const build = shell.exec(`cd ${path.resolve(appPath, 'admin')} && APP_PATH=${appPath} npm run build`, {
|
const build = shell.exec(`cd "${path.resolve(appPath, 'admin')}" && APP_PATH="${appPath}" npm run build`, {
|
||||||
silent
|
silent
|
||||||
});
|
});
|
||||||
|
|
||||||
@ -58,23 +58,23 @@ if (process.env.npm_config_plugins === 'true') {
|
|||||||
shell.ls('* -d', plugins).forEach(function (plugin) {
|
shell.ls('* -d', plugins).forEach(function (plugin) {
|
||||||
shell.echo(`🔸 Plugin - ${_.upperFirst(plugin)}`);
|
shell.echo(`🔸 Plugin - ${_.upperFirst(plugin)}`);
|
||||||
shell.echo('📦 Installing packages...');
|
shell.echo('📦 Installing packages...');
|
||||||
shell.exec(`cd ${path.resolve(plugins, plugin)} && npm install`, {
|
shell.exec(`cd "${path.resolve(plugins, plugin)}" && npm install`, {
|
||||||
silent
|
silent
|
||||||
});
|
});
|
||||||
|
|
||||||
if (isDevelopmentMode) {
|
if (isDevelopmentMode) {
|
||||||
shell.exec(`cd ${path.resolve(plugins, plugin)} && npm link strapi-helper-plugin`, {
|
shell.exec(`cd "${path.resolve(plugins, plugin)}" && npm link strapi-helper-plugin`, {
|
||||||
silent
|
silent
|
||||||
});
|
});
|
||||||
} else {
|
} else {
|
||||||
shell.exec(`cd ${path.resolve(plugins, plugin, 'node_modules', 'strapi-helper-plugin')} && npm install`, {
|
shell.exec(`cd "${path.resolve(plugins, plugin, 'node_modules', 'strapi-helper-plugin')}" && npm install`, {
|
||||||
silent
|
silent
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
shell.echo('🏗 Building...');
|
shell.echo('🏗 Building...');
|
||||||
|
|
||||||
const build = shell.exec(`cd ${path.resolve(plugins, plugin)} && APP_PATH=${appPath} npm run build`, {
|
const build = shell.exec(`cd "${path.resolve(plugins, plugin)}" && APP_PATH="${appPath}" npm run build`, {
|
||||||
silent
|
silent
|
||||||
});
|
});
|
||||||
|
|
||||||
|
|||||||
@ -18,7 +18,7 @@ module.exports = (scope, success, error) => {
|
|||||||
knex.raw('select 1+1 as result').then(() => {
|
knex.raw('select 1+1 as result').then(() => {
|
||||||
logger.info('The app has been connected to the database successfully');
|
logger.info('The app has been connected to the database successfully');
|
||||||
knex.destroy();
|
knex.destroy();
|
||||||
execSync(`rm -r ${scope.tmpPath}`);
|
execSync(`rm -r "${scope.tmpPath}"`);
|
||||||
|
|
||||||
logger.info('Copying the dashboard...');
|
logger.info('Copying the dashboard...');
|
||||||
|
|
||||||
|
|||||||
@ -32,7 +32,7 @@ module.exports = (scope, success, error) => {
|
|||||||
|
|
||||||
Mongoose.connection.close();
|
Mongoose.connection.close();
|
||||||
|
|
||||||
execSync(`rm -r ${scope.tmpPath}`);
|
execSync(`rm -r "${scope.tmpPath}"`);
|
||||||
|
|
||||||
logger.info('Copying the dashboard...');
|
logger.info('Copying the dashboard...');
|
||||||
|
|
||||||
|
|||||||
@ -26,7 +26,7 @@ module.exports = (scope, success, error) => {
|
|||||||
|
|
||||||
logger.info('The app has been connected to the database successfully!');
|
logger.info('The app has been connected to the database successfully!');
|
||||||
|
|
||||||
execSync(`rm -r ${scope.tmpPath}`);
|
execSync(`rm -r "${scope.tmpPath}"`);
|
||||||
|
|
||||||
logger.info('Copying the dashboard...');
|
logger.info('Copying the dashboard...');
|
||||||
|
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user