@cocreate/config 1.0.2 → 1.0.4
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.
- package/CHANGELOG.md +14 -0
- package/package.json +2 -3
- package/src/server.js +0 -15
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,17 @@
|
|
|
1
|
+
## [1.0.4](https://github.com/CoCreate-app/CoCreate-config/compare/v1.0.3...v1.0.4) (2023-06-14)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Bug Fixes
|
|
5
|
+
|
|
6
|
+
* handling of choices ([6b1844d](https://github.com/CoCreate-app/CoCreate-config/commit/6b1844d108ec4a679c44a4b3fa694841ff2161e6))
|
|
7
|
+
|
|
8
|
+
## [1.0.3](https://github.com/CoCreate-app/CoCreate-config/compare/v1.0.2...v1.0.3) (2023-06-14)
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
### Bug Fixes
|
|
12
|
+
|
|
13
|
+
* Update dependencies versions for [@cocreate](https://github.com/cocreate) libraries ([236cf62](https://github.com/CoCreate-app/CoCreate-config/commit/236cf6270e06b648d0996a4c2bd73e706fa52a91))
|
|
14
|
+
|
|
1
15
|
## [1.0.2](https://github.com/CoCreate-app/CoCreate-config/compare/v1.0.1...v1.0.2) (2023-06-14)
|
|
2
16
|
|
|
3
17
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@cocreate/config",
|
|
3
|
-
"version": "1.0.
|
|
3
|
+
"version": "1.0.4",
|
|
4
4
|
"description": "A convenient chain handler allows user to chain multiple CoCreate components together. When one action is complete next one will start. The sequence goes untill all config completed. Grounded on Vanilla javascript, easily configured using HTML5 attributes and/or JavaScript API.",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"config",
|
|
@@ -59,7 +59,6 @@
|
|
|
59
59
|
"webpack-log": "^3.0.1"
|
|
60
60
|
},
|
|
61
61
|
"dependencies": {
|
|
62
|
-
"@cocreate/
|
|
63
|
-
"@cocreate/utils": "^1.21.15"
|
|
62
|
+
"@cocreate/utils": "^1.21.16"
|
|
64
63
|
}
|
|
65
64
|
}
|
package/src/server.js
CHANGED
|
@@ -52,21 +52,6 @@ module.exports = async function (items, env = true, global = true) {
|
|
|
52
52
|
|
|
53
53
|
if (choices) {
|
|
54
54
|
if (!prompt && prompt !== '' || !choices) continue;
|
|
55
|
-
for (let choice of Object.keys(choices)) {
|
|
56
|
-
let choiceKey = choices[choice].key
|
|
57
|
-
if (process.env[choiceKey]) {
|
|
58
|
-
config[choiceKey] = process.env[choiceKey];
|
|
59
|
-
return;
|
|
60
|
-
} else if (localConfig[choiceKey]) {
|
|
61
|
-
config[choiceKey] = localConfig[choiceKey];
|
|
62
|
-
return;
|
|
63
|
-
|
|
64
|
-
} else if (globalConfig[choiceKey]) {
|
|
65
|
-
config[choiceKey] = globalConfig[choiceKey];
|
|
66
|
-
return;
|
|
67
|
-
}
|
|
68
|
-
}
|
|
69
|
-
|
|
70
55
|
const answer = await promptForInput(prompt || `${key}: `);
|
|
71
56
|
const choice = choices[answer];
|
|
72
57
|
if (choice) {
|