@eui/cli 18.2.0-snapshot-1727658460518 → 18.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.
@@ -1 +1 @@
1
- 18.2.0-snapshot-1727658460518
1
+ 18.2.0
package/lib/cli.js CHANGED
@@ -25,90 +25,87 @@ module.exports.start = (options) => {
25
25
  }
26
26
 
27
27
  // CLI interactions
28
- return Promise.resolve()
29
- .then(() => {
30
- return inquirer.prompt([
31
- {
32
- type: 'list',
33
- name: 'appType',
34
- message: 'Select an application type :',
35
- choices: [
36
- { name: 'eUI Angular - Desktop', value: 'angular' },
37
- { name: 'eUI Angular - Mobile Ionic', value: 'mobile' },
38
- { name: 'eUI Angular + Spring Boot web module - JDK + Maven required !!!', value: 'web-spring-boot' },
39
- { name: 'eUI Angular + Maven web module (JEE Spring maven web module) - JDK + Maven required !!!', value: 'web-maven' },
40
- { name: 'eUI Angular + PHP/Symfony starter - PHP7 and composer required !!!', value: 'web-symfony' },
41
- ],
42
- default: 0,
43
- validate: function (value) {
44
- if (value.length) {
45
- return true;
46
- }
47
- }
48
- },
49
- {
50
- name: 'groupId',
51
- type: 'input',
52
- message: 'Enter the groupId :',
53
- default: defaultConfig.groupId,
54
- validate: function (value) {
55
- if (value.length) {
56
- return true;
57
- }
58
- },
59
- when: function (answers) {
60
- return (answers.appType === 'web-spring-boot');
61
- }
62
- },
63
- {
64
- name: 'artifactId',
65
- type: 'input',
66
- message: 'Enter the artifactId :',
67
- default: defaultConfig.artifactId,
68
- validate: function (value) {
69
- if (value.length) {
70
- return true;
71
- }
72
- },
73
- when: function (answers) {
74
- return (answers.appType === 'web-spring-boot');
75
- }
76
- },
77
- {
78
- type: 'checkbox',
79
- name: 'appOptions',
80
- default: defaultConfig.appOptions,
81
- message: 'Select one or more additional configuration options :',
82
- choices: [
83
- { name: 'eUI ECL app-shell template and configuration - for ec.europa.eu apps', value: 'ecl' },
84
- ],
85
- when: function (answers) {
86
- return (answers.appType !== 'mobile');
87
- }
88
- },
28
+ return inquirer.prompt([
29
+ {
30
+ type: 'list',
31
+ name: 'appType',
32
+ message: 'Select an application type :',
33
+ choices: [
34
+ { name: 'eUI Angular - Desktop', value: 'angular' },
35
+ { name: 'eUI Angular - Mobile Ionic', value: 'mobile' },
36
+ { name: 'eUI Angular + Spring Boot web module - JDK + Maven required !!!', value: 'web-spring-boot' },
37
+ { name: 'eUI Angular + Maven web module (JEE Spring maven web module) - JDK + Maven required !!!', value: 'web-maven' },
38
+ { name: 'eUI Angular + PHP/Symfony starter - PHP7 and composer required !!!', value: 'web-symfony' },
39
+ ],
40
+ default: 0,
41
+ validate: function (value) {
42
+ if (value.length) {
43
+ return true;
44
+ }
45
+ }
46
+ },
47
+ {
48
+ name: 'groupId',
49
+ type: 'input',
50
+ message: 'Enter the groupId :',
51
+ default: defaultConfig.groupId,
52
+ validate: function (value) {
53
+ if (value.length) {
54
+ return true;
55
+ }
56
+ },
57
+ when: function (answers) {
58
+ return (answers.appType === 'web-spring-boot');
59
+ }
60
+ },
61
+ {
62
+ name: 'artifactId',
63
+ type: 'input',
64
+ message: 'Enter the artifactId :',
65
+ default: defaultConfig.artifactId,
66
+ validate: function (value) {
67
+ if (value.length) {
68
+ return true;
69
+ }
70
+ },
71
+ when: function (answers) {
72
+ return (answers.appType === 'web-spring-boot');
73
+ }
74
+ },
75
+ {
76
+ type: 'checkbox',
77
+ name: 'appOptions',
78
+ default: defaultConfig.appOptions,
79
+ message: 'Select one or more additional configuration options :',
80
+ choices: [
81
+ { name: 'eUI ECL app-shell template and configuration - for ec.europa.eu apps', value: 'ecl' },
82
+ ],
83
+ when: function (answers) {
84
+ return (answers.appType !== 'mobile');
85
+ }
86
+ },
89
87
 
90
- {
91
- type: 'list',
92
- name: 'appOptionsEclTheme',
93
- default: defaultConfig.appOptionsEclTheme,
94
- message: 'Select which eUI ECL theme flavor you need :',
95
- choices: [
96
- { name: 'eUI ECL - EC theme', value: 'ecl-ec' },
97
- { name: 'eUI ECL - EU theme', value: 'ecl-eu' },
98
- ],
99
- when: function (answers) {
100
- return (answers.appOptions && answers.appOptions.includes('ecl') && answers.appType !== 'mobile');
101
- }
102
- },
88
+ {
89
+ type: 'list',
90
+ name: 'appOptionsEclTheme',
91
+ default: defaultConfig.appOptionsEclTheme,
92
+ message: 'Select which eUI ECL theme flavor you need :',
93
+ choices: [
94
+ { name: 'eUI ECL - EC theme', value: 'ecl-ec' },
95
+ { name: 'eUI ECL - EU theme', value: 'ecl-eu' },
96
+ ],
97
+ when: function (answers) {
98
+ return (answers.appOptions && answers.appOptions.includes('ecl') && answers.appType !== 'mobile');
99
+ }
100
+ },
103
101
 
104
- {
105
- name: 'npmInstall',
106
- type: 'confirm',
107
- message: 'Yarn install dependencies when the app is generated :',
108
- default: defaultConfig.npmInstall
109
- }
110
- ]);
111
- })
102
+ {
103
+ name: 'npmInstall',
104
+ type: 'confirm',
105
+ message: 'Yarn install dependencies when the app is generated :',
106
+ default: defaultConfig.npmInstall
107
+ }
108
+ ])
112
109
  .then((answers) => {
113
110
  let outputConfig;
114
111
  outputConfig = {
package/lib/generators.js CHANGED
@@ -15,69 +15,54 @@ const appGenerate = (options) => {
15
15
  console.info(chalk.cyan('Configuring your project : please answer the following : \n'));
16
16
  }
17
17
 
18
- let cliConfig;
19
-
20
18
  // Query the questions
21
19
  // -------------------
22
- return Promise.resolve()
23
- .then(() => {
24
- return cli.start(options);
25
- })
26
-
27
- // Storing config
28
- // --------------
20
+ return cli.start(options)
29
21
  .then((config) => {
30
- cliConfig = config;
31
- console.log(config);
32
- })
33
-
34
- // Building the file structure
35
- // ---------------------------
36
- .then(() => {
22
+ // Storing config
23
+ // --------------
24
+ const cliConfig = config;
25
+ // Building the file structure
26
+ // ---------------------------
37
27
  return build.start({
38
- config: cliConfig,
39
- targetPath: options.targetPath
40
- });
41
- })
42
-
43
- // Post build operations
44
- // ---------------------
45
- .then(() => {
46
- return postBuild.start({
47
- config: cliConfig,
28
+ config: config,
48
29
  targetPath: options.targetPath
49
- });
50
- })
30
+ })
31
+ // Post build operations
32
+ // ---------------------
33
+ .then(() => {
34
+ return postBuild.start({
35
+ config: cliConfig,
36
+ targetPath: options.targetPath
37
+ });
38
+ })
39
+ // Install dependencies
40
+ // --------------------
41
+ .then(() => {
42
+ return install.start({
43
+ config: cliConfig,
44
+ targetPath: options.targetPath,
45
+ });
46
+ })
47
+ // starting app
48
+ .then(() => {
49
+ if (!cliConfig.appStart || typeof cliConfig.npmInstall !== 'boolean' || !cliConfig.npmInstall) {
50
+ return;
51
+ }
52
+ console.log('');
53
+ console.log('');
54
+ console.log('*****************************************************************');
55
+ console.log(chalk.cyan(' Starting eUI app... browser will open soon on localhost:4200'));
56
+ console.log('*****************************************************************');
51
57
 
52
- // Install dependencies
53
- // --------------------
54
- .then(() => {
55
- return install.start({
56
- config: cliConfig,
57
- targetPath: options.targetPath,
58
- });
58
+ const wd = path.resolve(utils.getAngularPath(options.targetPath, cliConfig.appName, cliConfig.appType, cliConfig.artifactId));
59
+ return execSync("npm start", { cwd: wd, stdio: "inherit" });
60
+ })
59
61
  })
60
-
61
- // starting app
62
- .then(() => {
63
- if (!cliConfig.appStart) {
64
- return;
65
- }
66
- console.log('');
67
- console.log('');
68
- console.log('*****************************************************************');
69
- console.log(chalk.cyan(' Starting eUI app... browser will open soon on localhost:4200'));
70
- console.log('*****************************************************************');
71
-
72
- const wd = path.resolve(utils.getAngularPath(options.targetPath, cliConfig.appName, cliConfig.appType, cliConfig.artifactId));
73
- return execSync("npm start", { cwd: wd, stdio: "inherit" });
74
- })
75
-
76
62
  .catch((e) => {
77
63
  console.error(e);
78
64
  process.exitCode = 1;
79
65
  })
80
-
81
66
  .finally(() => process.exit())
82
67
  }
83
68
 
package/lib/install.js CHANGED
@@ -7,7 +7,7 @@ const chalk = require('chalk');
7
7
 
8
8
  module.exports.start = (options) => {
9
9
 
10
- if (!options.config.npmInstall) {
10
+ if (typeof options.config.npmInstall !== 'boolean' || !options.config.npmInstall) {
11
11
  return;
12
12
  }
13
13
 
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "eui-angular-app",
3
- "version": "18.2.0-snapshot-1727658460518",
3
+ "version": "18.2.0",
4
4
  "license": "EUPL-1.1",
5
5
  "scripts": {
6
6
  "ng": "ng",
@@ -21,7 +21,7 @@
21
21
  },
22
22
  "private": true,
23
23
  "dependencies": {
24
- "@eui/deps-base": "18.2.0-snapshot-1727658460518"
24
+ "@eui/deps-base": "18.2.0"
25
25
  },
26
26
  "resolutions": {
27
27
  "js-yaml": ">=3.13.1",
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "eui-angular-app",
3
- "version": "18.2.0-snapshot-1727658460518",
3
+ "version": "18.2.0",
4
4
  "license": "EUPL-1.1",
5
5
  "scripts": {
6
6
  "ng": "ng",
@@ -20,8 +20,8 @@
20
20
  },
21
21
  "private": true,
22
22
  "dependencies": {
23
- "@eui/deps-base": "16.2.19-snapshot-1721355158108",
24
- "@eui/mobile-core": "16.10.1-snapshot-1714734024630",
25
- "@eui/mobile-styles": "16.10.1-snapshot-1714734024630"
23
+ "@eui/deps-base": "16.2.18",
24
+ "@eui/mobile-core": "16.10.0",
25
+ "@eui/mobile-styles": "16.10.0"
26
26
  }
27
27
  }
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "eui-angular-app",
3
- "version": "18.2.0-snapshot-1727658460518",
3
+ "version": "18.2.0",
4
4
  "license": "EUPL-1.1",
5
5
  "description": "eUI JEE Symfony app scripts",
6
6
  "scripts": {
@@ -18,6 +18,6 @@
18
18
  },
19
19
  "private": true,
20
20
  "dependencies": {
21
- "@eui/deps-base": "18.2.0-snapshot-1727658460518"
21
+ "@eui/deps-base": "18.2.0"
22
22
  }
23
23
  }
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@eui/cli",
3
- "version": "18.2.0-snapshot-1727658460518",
4
- "tag": "snapshot",
3
+ "version": "18.2.0",
4
+ "tag": "latest",
5
5
  "license": "EUPL-1.1",
6
6
  "description": "eUI CLI app generator",
7
7
  "bin": {