create-strapi-app 4.2.0-beta.2 → 4.2.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -37,7 +37,6 @@ program
37
37
  .option('--dbfile <dbfile>', 'Database file path for sqlite')
38
38
  .option('--dbforce', 'Overwrite database content if any')
39
39
  .option('--template <templateurl>', 'Specify a Strapi template')
40
- .option('--ts, --typescript', 'Use TypeScript to generate the project')
41
40
  .description('create a new application')
42
41
  .action(directory => {
43
42
  initProject(directory, program);
@@ -81,8 +80,7 @@ async function initProject(projectName, program) {
81
80
  return generateApp(projectName, program);
82
81
  }
83
82
 
84
- const prompt = await promptUser(projectName, program);
85
-
83
+ const prompt = await promptUser(projectName, program, hasDatabaseOptions);
86
84
  const directory = prompt.directory || projectName;
87
85
  await checkInstallPath(resolve(directory));
88
86
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "create-strapi-app",
3
- "version": "4.2.0-beta.2",
3
+ "version": "4.2.0",
4
4
  "description": "Generate a new Strapi application.",
5
5
  "keywords": [
6
6
  "create-strapi-app",
@@ -38,13 +38,13 @@
38
38
  "test": "echo \"no tests yet\""
39
39
  },
40
40
  "dependencies": {
41
- "@strapi/generate-new": "4.2.0-beta.2",
41
+ "@strapi/generate-new": "4.2.0",
42
42
  "commander": "6.1.0",
43
43
  "inquirer": "8.2.0"
44
44
  },
45
45
  "engines": {
46
- "node": ">=12.22.0 <=16.x.x",
46
+ "node": ">=14.19.1 <=16.x.x",
47
47
  "npm": ">=6.0.0"
48
48
  },
49
- "gitHead": "bff73257e7695d6f361c91dda8cc810a2bb70b6e"
49
+ "gitHead": "12c8ee3b2d95fe417de4d939db0311a0513bd8da"
50
50
  }
@@ -7,8 +7,8 @@ const inquirer = require('inquirer');
7
7
  * @param {string|null} template - The Github repo of the template
8
8
  * @returns Object containting prompt answers
9
9
  */
10
- module.exports = async function promptUser(projectName, program) {
11
- const questions = await getPromptQuestions(projectName, program);
10
+ module.exports = async function promptUser(projectName, program, hasDatabaseOptions) {
11
+ const questions = await getPromptQuestions(projectName, program, hasDatabaseOptions);
12
12
  return inquirer.prompt(questions);
13
13
  };
14
14
 
@@ -17,7 +17,7 @@ module.exports = async function promptUser(projectName, program) {
17
17
  * @param {string|null} template - The template the project should use
18
18
  * @returns Array of prompt question objects
19
19
  */
20
- async function getPromptQuestions(projectName, program) {
20
+ async function getPromptQuestions(projectName, program, hasDatabaseOptions) {
21
21
  return [
22
22
  {
23
23
  type: 'input',
@@ -30,7 +30,7 @@ async function getPromptQuestions(projectName, program) {
30
30
  type: 'list',
31
31
  name: 'quick',
32
32
  message: 'Choose your installation type',
33
- when: !program.quickstart,
33
+ when: !program.quickstart && !hasDatabaseOptions,
34
34
  choices: [
35
35
  {
36
36
  name: 'Quickstart (recommended)',