From bc7ff4be9cde21f9fea194d1a94091c3c7a072fd Mon Sep 17 00:00:00 2001 From: Ronald Langeveld Date: Thu, 15 Feb 2024 14:48:08 +0200 Subject: [PATCH] Added no-seed flag to yarn setup. (#19697) refs https://ghost.slack.com/archives/C02G9E68C/p1707994528206559 - When running Ghost development and using MySQL + Docker, you can run the command `yarn setup --no-seed` to not have the database seeded with test data. --- .github/scripts/setup.js | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/.github/scripts/setup.js b/.github/scripts/setup.js index 42edcdd2ee..f0558b298d 100644 --- a/.github/scripts/setup.js +++ b/.github/scripts/setup.js @@ -119,7 +119,11 @@ async function runAndStream(command, args, options) { console.log(chalk.blue(`Running knex-migrator init`)); await runAndStream('yarn', ['knex-migrator', 'init'], {cwd: coreFolder}); - + if (process.argv.includes('--no-seed')) { + console.log(chalk.yellow(`Skipping seed data`)); + console.log(chalk.yellow(`Done`)); + return; + } if (resetData) { const xxl = process.argv.includes('--xxl');