json-crud-ui 1.1.4 → 1.2.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/bin/v2/commands/init/steps/locateSource.js +32 -0
- package/package.json +1 -1
- package/bin/v1/commands/init/steps/locateSource.js +0 -16
- /package/bin/{v1 → v2}/commands/init/steps/announce.js +0 -0
- /package/bin/{v1 → v2}/commands/init/steps/createProject.js +0 -0
- /package/bin/{v1 → v2}/commands/init/steps/locateDestination.js +0 -0
- /package/bin/{v1 → v2}/commands/init/steps/resolveFolderName.js +0 -0
- /package/bin/{v1 → v2}/commands/init/template/v1/Index/FormLoad/DomContentLoaded/buildHeader.js +0 -0
- /package/bin/{v1 → v2}/commands/init/template/v1/Index/FormLoad/DomContentLoaded/buildMenuItem.js +0 -0
- /package/bin/{v1 → v2}/commands/init/template/v1/Index/FormLoad/DomContentLoaded/runAfterDomLoad.js +0 -0
- /package/bin/{v1 → v2}/commands/init/template/v1/Index/FormLoad/DomContentLoaded/start.js +0 -0
- /package/bin/{v1 → v2}/commands/init/template/v1/Index/FormLoad/start.js +0 -0
- /package/bin/{v1 → v2}/commands/init/template/v1/Index/start.js +0 -0
- /package/bin/{v1 → v2}/commands/init/template/v2/FormLoad/DomContentLoaded/buildHeader.js +0 -0
- /package/bin/{v1 → v2}/commands/init/template/v2/FormLoad/DomContentLoaded/buildMenuItem.js +0 -0
- /package/bin/{v1 → v2}/commands/init/template/v2/FormLoad/DomContentLoaded/runAfterDomLoad.js +0 -0
- /package/bin/{v1 → v2}/commands/init/template/v2/FormLoad/DomContentLoaded/start.js +0 -0
- /package/bin/{v1 → v2}/commands/init/template/v2/FormLoad/start.js +0 -0
- /package/bin/{v1 → v2}/commands/init/template/v2/start.js +0 -0
- /package/bin/{v1 → v2}/commands/init/template/v3/FormLoad/DomContentLoaded/buildHeader.js +0 -0
- /package/bin/{v1 → v2}/commands/init/template/v3/FormLoad/DomContentLoaded/buildMenuItem.js +0 -0
- /package/bin/{v1 → v2}/commands/init/template/v3/FormLoad/DomContentLoaded/runAfterDomLoad.js +0 -0
- /package/bin/{v1 → v2}/commands/init/template/v3/FormLoad/DomContentLoaded/start.js +0 -0
- /package/bin/{v1 → v2}/commands/init/template/v3/FormLoad/start.js +0 -0
- /package/bin/{v1 → v2}/commands/init/template/v3/headers.json +0 -0
- /package/bin/{v1 → v2}/commands/init/template/v3/start.js +0 -0
- /package/bin/{v1 → v2}/commands/init.js +0 -0
- /package/bin/{v1 → v2}/core/parseInput.js +0 -0
- /package/bin/{v1 → v2}/core/resolveCommand.js +0 -0
- /package/bin/{v1 → v2}/core/showUsage.js +0 -0
- /package/bin/{v1 → v2}/start.js +0 -0
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
import fs from "fs";
|
|
2
|
+
|
|
3
|
+
import path from "path";
|
|
4
|
+
import { fileURLToPath } from "url";
|
|
5
|
+
|
|
6
|
+
const __filename = fileURLToPath(import.meta.url);
|
|
7
|
+
const __dirname = path.dirname(__filename);
|
|
8
|
+
|
|
9
|
+
const templatePath = path.join(
|
|
10
|
+
__dirname,
|
|
11
|
+
"..",
|
|
12
|
+
"template"
|
|
13
|
+
);
|
|
14
|
+
|
|
15
|
+
const versions = fs
|
|
16
|
+
.readdirSync(templatePath)
|
|
17
|
+
.filter(item => item.startsWith("v"));
|
|
18
|
+
|
|
19
|
+
const highestVersion =
|
|
20
|
+
versions.sort().at(-1);
|
|
21
|
+
|
|
22
|
+
const sourceVersion =
|
|
23
|
+
highestVersion;
|
|
24
|
+
|
|
25
|
+
export const locateSource = () => {
|
|
26
|
+
return path.join(
|
|
27
|
+
__dirname,
|
|
28
|
+
"..",
|
|
29
|
+
"template",
|
|
30
|
+
sourceVersion
|
|
31
|
+
);
|
|
32
|
+
};
|
package/package.json
CHANGED
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
import path from "path";
|
|
2
|
-
import { fileURLToPath } from "url";
|
|
3
|
-
|
|
4
|
-
const __filename = fileURLToPath(import.meta.url);
|
|
5
|
-
const __dirname = path.dirname(__filename);
|
|
6
|
-
|
|
7
|
-
const sourceVersion = "v1";
|
|
8
|
-
|
|
9
|
-
export const locateSource = () => {
|
|
10
|
-
return path.join(
|
|
11
|
-
__dirname,
|
|
12
|
-
"..",
|
|
13
|
-
"template",
|
|
14
|
-
sourceVersion
|
|
15
|
-
);
|
|
16
|
-
};
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
/package/bin/{v1 → v2}/commands/init/template/v1/Index/FormLoad/DomContentLoaded/buildHeader.js
RENAMED
|
File without changes
|
/package/bin/{v1 → v2}/commands/init/template/v1/Index/FormLoad/DomContentLoaded/buildMenuItem.js
RENAMED
|
File without changes
|
/package/bin/{v1 → v2}/commands/init/template/v1/Index/FormLoad/DomContentLoaded/runAfterDomLoad.js
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
/package/bin/{v1 → v2}/commands/init/template/v2/FormLoad/DomContentLoaded/runAfterDomLoad.js
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
/package/bin/{v1 → v2}/commands/init/template/v3/FormLoad/DomContentLoaded/runAfterDomLoad.js
RENAMED
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
|
File without changes
|
/package/bin/{v1 → v2}/start.js
RENAMED
|
File without changes
|