@youcan/create-app 2.4.4 → 2.5.1
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/dist/services/init.js +9 -1
- package/package.json +6 -2
package/dist/services/init.js
CHANGED
|
@@ -31,7 +31,15 @@ async function initService(command, options) {
|
|
|
31
31
|
{
|
|
32
32
|
title: 'Configuring app...',
|
|
33
33
|
task: async () => {
|
|
34
|
-
|
|
34
|
+
const configPath = Path.join(templateDownloadDirectory, 'youcan.app.json');
|
|
35
|
+
const configExists = await Filesystem.exists(configPath);
|
|
36
|
+
if (configExists) {
|
|
37
|
+
const existingConfig = await Filesystem.readJsonFile(configPath);
|
|
38
|
+
await Filesystem.writeJsonFile(configPath, { ...existingConfig, name: slug });
|
|
39
|
+
}
|
|
40
|
+
else {
|
|
41
|
+
await Filesystem.writeJsonFile(configPath, { name: slug });
|
|
42
|
+
}
|
|
35
43
|
},
|
|
36
44
|
},
|
|
37
45
|
{
|
package/package.json
CHANGED
|
@@ -1,10 +1,14 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@youcan/create-app",
|
|
3
3
|
"type": "module",
|
|
4
|
-
"version": "2.
|
|
4
|
+
"version": "2.5.1",
|
|
5
5
|
"description": "A CLI for creating YouCan Shop apps",
|
|
6
6
|
"author": "YouCan <contact@youcan.shop> (https://youcan.shop)",
|
|
7
7
|
"license": "MIT",
|
|
8
|
+
"repository": {
|
|
9
|
+
"type": "git",
|
|
10
|
+
"url": "https://github.com/youcan-shop/cli"
|
|
11
|
+
},
|
|
8
12
|
"keywords": [
|
|
9
13
|
"youcan",
|
|
10
14
|
"youcan-cli",
|
|
@@ -23,7 +27,7 @@
|
|
|
23
27
|
],
|
|
24
28
|
"dependencies": {
|
|
25
29
|
"@oclif/core": "^2.15.0",
|
|
26
|
-
"@youcan/cli-kit": "2.
|
|
30
|
+
"@youcan/cli-kit": "2.5.1"
|
|
27
31
|
},
|
|
28
32
|
"devDependencies": {
|
|
29
33
|
"@oclif/plugin-legacy": "^1.3.0",
|