@slicemachine/init 2.10.44-beta.4 → 2.10.44-beta.5
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/slicemachine-init.js
CHANGED
|
@@ -1,3 +1,31 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
|
|
3
|
+
import semver from "semver";
|
|
4
|
+
import { readFileSync } from "node:fs";
|
|
5
|
+
import { fileURLToPath } from "node:url";
|
|
6
|
+
import { dirname, join } from "node:path";
|
|
7
|
+
import chalk from "chalk";
|
|
8
|
+
|
|
9
|
+
const __dirname = dirname(fileURLToPath(import.meta.url));
|
|
10
|
+
const pkg = JSON.parse(
|
|
11
|
+
readFileSync(join(__dirname, "../package.json"), "utf8"),
|
|
12
|
+
);
|
|
13
|
+
|
|
14
|
+
const requiredVersion = pkg.engines.node;
|
|
15
|
+
|
|
16
|
+
if (!requiredVersion) {
|
|
17
|
+
throw new Error("Missing engines.node in package.json.");
|
|
18
|
+
}
|
|
19
|
+
|
|
20
|
+
const currentVersion = process.version;
|
|
21
|
+
|
|
22
|
+
if (!semver.satisfies(currentVersion, requiredVersion)) {
|
|
23
|
+
console.warn(
|
|
24
|
+
chalk.yellow(
|
|
25
|
+
`⚠️ Warning: You are using Node.js ${currentVersion}, but this tool requires ${requiredVersion}.\n` +
|
|
26
|
+
` Some features may not work correctly. Please upgrade your Node.js version.\n`,
|
|
27
|
+
),
|
|
28
|
+
);
|
|
29
|
+
}
|
|
30
|
+
|
|
3
31
|
import("../dist/cli.cjs");
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
|
|
3
3
|
const name = "@slicemachine/init";
|
|
4
|
-
const version = "2.10.44-beta.
|
|
4
|
+
const version = "2.10.44-beta.5";
|
|
5
5
|
const description = "Init Prismic Slice Machine in your project";
|
|
6
6
|
const keywords = [
|
|
7
7
|
"typescript",
|
|
@@ -95,6 +95,9 @@ const devDependencies = {
|
|
|
95
95
|
"vite-plugin-sdk": "0.1.1",
|
|
96
96
|
vitest: "0.32.0"
|
|
97
97
|
};
|
|
98
|
+
const engines = {
|
|
99
|
+
node: ">=20.19.0"
|
|
100
|
+
};
|
|
98
101
|
const publishConfig = {
|
|
99
102
|
access: "public"
|
|
100
103
|
};
|
|
@@ -117,6 +120,7 @@ const pkg = {
|
|
|
117
120
|
scripts,
|
|
118
121
|
dependencies,
|
|
119
122
|
devDependencies,
|
|
123
|
+
engines,
|
|
120
124
|
publishConfig,
|
|
121
125
|
stableVersion
|
|
122
126
|
};
|
|
@@ -126,6 +130,7 @@ exports.default = pkg;
|
|
|
126
130
|
exports.dependencies = dependencies;
|
|
127
131
|
exports.description = description;
|
|
128
132
|
exports.devDependencies = devDependencies;
|
|
133
|
+
exports.engines = engines;
|
|
129
134
|
exports.exports = exports$1;
|
|
130
135
|
exports.files = files;
|
|
131
136
|
exports.keywords = keywords;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"package.json.cjs","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"package.json.cjs","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
const name = "@slicemachine/init";
|
|
2
|
-
const version = "2.10.44-beta.
|
|
2
|
+
const version = "2.10.44-beta.5";
|
|
3
3
|
const description = "Init Prismic Slice Machine in your project";
|
|
4
4
|
const keywords = [
|
|
5
5
|
"typescript",
|
|
@@ -93,6 +93,9 @@ const devDependencies = {
|
|
|
93
93
|
"vite-plugin-sdk": "0.1.1",
|
|
94
94
|
vitest: "0.32.0"
|
|
95
95
|
};
|
|
96
|
+
const engines = {
|
|
97
|
+
node: ">=20.19.0"
|
|
98
|
+
};
|
|
96
99
|
const publishConfig = {
|
|
97
100
|
access: "public"
|
|
98
101
|
};
|
|
@@ -115,6 +118,7 @@ const pkg = {
|
|
|
115
118
|
scripts,
|
|
116
119
|
dependencies,
|
|
117
120
|
devDependencies,
|
|
121
|
+
engines,
|
|
118
122
|
publishConfig,
|
|
119
123
|
stableVersion
|
|
120
124
|
};
|
|
@@ -125,6 +129,7 @@ export {
|
|
|
125
129
|
dependencies,
|
|
126
130
|
description,
|
|
127
131
|
devDependencies,
|
|
132
|
+
engines,
|
|
128
133
|
exports,
|
|
129
134
|
files,
|
|
130
135
|
keywords,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"package.json.js","sources":[],"sourcesContent":[],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"package.json.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@slicemachine/init",
|
|
3
|
-
"version": "2.10.44-beta.
|
|
3
|
+
"version": "2.10.44-beta.5",
|
|
4
4
|
"description": "Init Prismic Slice Machine in your project",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"typescript",
|
|
@@ -54,7 +54,7 @@
|
|
|
54
54
|
"@antfu/ni": "^0.20.0",
|
|
55
55
|
"@lihbr/listr-update-renderer": "^0.5.3",
|
|
56
56
|
"@sentry/node": "^7.116.0",
|
|
57
|
-
"@slicemachine/manager": "0.26.1-beta.
|
|
57
|
+
"@slicemachine/manager": "0.26.1-beta.5",
|
|
58
58
|
"chalk": "^4.1.2",
|
|
59
59
|
"giget": "^1.1.2",
|
|
60
60
|
"globby": "^13.1.3",
|
|
@@ -68,7 +68,7 @@
|
|
|
68
68
|
},
|
|
69
69
|
"devDependencies": {
|
|
70
70
|
"@size-limit/preset-small-lib": "8.2.4",
|
|
71
|
-
"@slicemachine/plugin-kit": "0.4.86-beta.
|
|
71
|
+
"@slicemachine/plugin-kit": "0.4.86-beta.6",
|
|
72
72
|
"@types/listr": "0.14.4",
|
|
73
73
|
"@types/prompts": "2.4.3",
|
|
74
74
|
"@types/semver": "7.3.13",
|
|
@@ -94,6 +94,9 @@
|
|
|
94
94
|
"vite-plugin-sdk": "0.1.1",
|
|
95
95
|
"vitest": "0.32.0"
|
|
96
96
|
},
|
|
97
|
+
"engines": {
|
|
98
|
+
"node": ">=20.19.0"
|
|
99
|
+
},
|
|
97
100
|
"publishConfig": {
|
|
98
101
|
"access": "public"
|
|
99
102
|
},
|