schemashift-cli 0.13.0 → 0.15.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.
- package/README.md +22 -2
- package/dist/cli.js +3 -19
- package/dist/index.cjs +0 -4
- package/dist/index.js +0 -4
- package/package.json +13 -12
package/README.md
CHANGED
|
@@ -1,6 +1,11 @@
|
|
|
1
1
|
# schemashift-cli
|
|
2
2
|
|
|
3
|
-
TypeScript schema migration CLI. Convert between Zod, Yup, Joi, io-ts, and
|
|
3
|
+
TypeScript schema migration CLI. Convert between Zod, Yup, Joi, io-ts, Valibot, ArkType, Superstruct, and Effect Schema with AST-based transformations.
|
|
4
|
+
|
|
5
|
+
[](https://www.npmjs.com/package/schemashift-cli)
|
|
6
|
+
[](https://www.npmjs.com/package/schemashift-cli)
|
|
7
|
+
[](https://github.com/jdmay2/schemashift/actions/workflows/ci.yml)
|
|
8
|
+
[](https://opensource.org/licenses/MIT)
|
|
4
9
|
|
|
5
10
|
## Install
|
|
6
11
|
|
|
@@ -221,10 +226,25 @@ schemashift rollback
|
|
|
221
226
|
|----------|-------------|
|
|
222
227
|
| `SCHEMASHIFT_LICENSE_KEY` | License key for CI/CD (avoids interactive activation) |
|
|
223
228
|
|
|
229
|
+
## Related Packages
|
|
230
|
+
|
|
231
|
+
| Package | Description |
|
|
232
|
+
|---------|-------------|
|
|
233
|
+
| [@schemashift/core](https://www.npmjs.com/package/@schemashift/core) | Core analysis and transformation engine |
|
|
234
|
+
| [@schemashift/yup-zod](https://www.npmjs.com/package/@schemashift/yup-zod) | Yup ↔ Zod transformer |
|
|
235
|
+
| [@schemashift/joi-zod](https://www.npmjs.com/package/@schemashift/joi-zod) | Joi → Zod transformer |
|
|
236
|
+
| [@schemashift/zod-v3-v4](https://www.npmjs.com/package/@schemashift/zod-v3-v4) | Zod v3 → v4 upgrade |
|
|
237
|
+
| [@schemashift/io-ts-zod](https://www.npmjs.com/package/@schemashift/io-ts-zod) | io-ts → Zod transformer |
|
|
238
|
+
| [@schemashift/zod-valibot](https://www.npmjs.com/package/@schemashift/zod-valibot) | Zod ↔ Valibot transformer |
|
|
239
|
+
| [@schemashift/zod-arktype](https://www.npmjs.com/package/@schemashift/zod-arktype) | Zod ↔ ArkType transformer |
|
|
240
|
+
| [@schemashift/zod-superstruct](https://www.npmjs.com/package/@schemashift/zod-superstruct) | Zod ↔ Superstruct transformer |
|
|
241
|
+
| [@schemashift/io-ts-effect](https://www.npmjs.com/package/@schemashift/io-ts-effect) | io-ts → Effect Schema transformer |
|
|
242
|
+
|
|
224
243
|
## Links
|
|
225
244
|
|
|
226
|
-
- [Documentation](https://schemashift.qwady.app/docs)
|
|
245
|
+
- [Documentation](https://schemashift.qwady.app/docs.html)
|
|
227
246
|
- [Pricing](https://schemashift.qwady.app)
|
|
247
|
+
- [Migration Guides](https://schemashift.qwady.app/migrate-yup-to-zod.html)
|
|
228
248
|
|
|
229
249
|
## License
|
|
230
250
|
|
package/dist/cli.js
CHANGED
|
@@ -35823,7 +35823,6 @@ var TIER_FEATURES = {
|
|
|
35823
35823
|
"free"
|
|
35824
35824
|
/* FREE */
|
|
35825
35825
|
]: {
|
|
35826
|
-
maxFiles: 10,
|
|
35827
35826
|
migrations: ["yup->zod", "joi->zod"],
|
|
35828
35827
|
devices: 1,
|
|
35829
35828
|
ciSupport: false,
|
|
@@ -35856,7 +35855,6 @@ var TIER_FEATURES = {
|
|
|
35856
35855
|
"individual"
|
|
35857
35856
|
/* INDIVIDUAL */
|
|
35858
35857
|
]: {
|
|
35859
|
-
maxFiles: Infinity,
|
|
35860
35858
|
migrations: ["yup->zod", "joi->zod", "zod-v3->v4"],
|
|
35861
35859
|
devices: 1,
|
|
35862
35860
|
ciSupport: false,
|
|
@@ -35889,7 +35887,6 @@ var TIER_FEATURES = {
|
|
|
35889
35887
|
"pro"
|
|
35890
35888
|
/* PRO */
|
|
35891
35889
|
]: {
|
|
35892
|
-
maxFiles: Infinity,
|
|
35893
35890
|
migrations: [
|
|
35894
35891
|
"yup->zod",
|
|
35895
35892
|
"joi->zod",
|
|
@@ -35936,7 +35933,6 @@ var TIER_FEATURES = {
|
|
|
35936
35933
|
"team"
|
|
35937
35934
|
/* TEAM */
|
|
35938
35935
|
]: {
|
|
35939
|
-
maxFiles: Infinity,
|
|
35940
35936
|
migrations: [
|
|
35941
35937
|
"yup->zod",
|
|
35942
35938
|
"joi->zod",
|
|
@@ -37971,13 +37967,6 @@ Compatibility score: ${pc5.cyan(compatResult.overallScore.toString())}%`);
|
|
|
37971
37967
|
incrementalTracker.start(files, options.from, options.to);
|
|
37972
37968
|
console.log(pc5.dim("Started incremental migration."));
|
|
37973
37969
|
}
|
|
37974
|
-
if (files.length > features.maxFiles) {
|
|
37975
|
-
console.error(
|
|
37976
|
-
pc5.red(`File limit exceeded. Found ${files.length}, max ${features.maxFiles}.`)
|
|
37977
|
-
);
|
|
37978
|
-
console.log(`Upgrade at: ${pc5.cyan(POLAR_URL)}`);
|
|
37979
|
-
process.exit(1);
|
|
37980
|
-
}
|
|
37981
37970
|
if (options.crossFile) {
|
|
37982
37971
|
const depResolver = new SchemaDependencyResolver();
|
|
37983
37972
|
const analyzer = new SchemaAnalyzer();
|
|
@@ -38395,9 +38384,6 @@ program.command("license").description("Show license information").option("-a, -
|
|
|
38395
38384
|
console.log(pc5.green("\nLicense activated successfully!\n"));
|
|
38396
38385
|
console.log(`Tier: ${pc5.cyan(result.license.tier)}`);
|
|
38397
38386
|
console.log(`Migrations: ${result.license.features.migrations.join(", ")}`);
|
|
38398
|
-
console.log(
|
|
38399
|
-
`Max files: ${result.license.features.maxFiles === Infinity ? "Unlimited" : result.license.features.maxFiles}`
|
|
38400
|
-
);
|
|
38401
38387
|
} else {
|
|
38402
38388
|
console.error(pc5.red(`
|
|
38403
38389
|
Activation failed: ${result.error}`));
|
|
@@ -38419,8 +38405,7 @@ Activation failed: ${result.error}`));
|
|
|
38419
38405
|
console.log(pc5.bold("\nLicense Status\n"));
|
|
38420
38406
|
if (!status.activated) {
|
|
38421
38407
|
console.log(`Tier: ${pc5.yellow("FREE")}`);
|
|
38422
|
-
console.log("
|
|
38423
|
-
console.log("Migrations: yup->zod only");
|
|
38408
|
+
console.log("Migrations: yup->zod, joi->zod");
|
|
38424
38409
|
console.log("\nActivate a license: schemashift license --activate <key>");
|
|
38425
38410
|
console.log(`Purchase: ${pc5.cyan(POLAR_URL)}`);
|
|
38426
38411
|
return;
|
|
@@ -38433,7 +38418,6 @@ Activation failed: ${result.error}`));
|
|
|
38433
38418
|
if (status.lastValidated)
|
|
38434
38419
|
console.log(`Last validated: ${status.lastValidated.toLocaleString()}`);
|
|
38435
38420
|
console.log("\nFeatures:");
|
|
38436
|
-
console.log(` Max files: ${features.maxFiles === Infinity ? "Unlimited" : features.maxFiles}`);
|
|
38437
38421
|
console.log(` Migrations: ${features.migrations.join(", ")}`);
|
|
38438
38422
|
console.log(` CI/CD: ${features.ciSupport ? pc5.green("Yes") : pc5.red("No")}`);
|
|
38439
38423
|
console.log(` HTML reports: ${features.htmlReports ? pc5.green("Yes") : pc5.red("No")}`);
|
|
@@ -38990,10 +38974,10 @@ program.command("policy [path]").description("Manage schema governance policies
|
|
|
38990
38974
|
program.command("pricing").description("Show pricing information").action(() => {
|
|
38991
38975
|
console.log(pc5.bold("\nSchemaShift Pricing\n"));
|
|
38992
38976
|
console.log(`${pc5.green("FREE")} - $0`);
|
|
38993
|
-
console.log("
|
|
38977
|
+
console.log(" Yup \u2192 Zod + Joi \u2192 Zod, JSON reports");
|
|
38994
38978
|
console.log(" Up to 5 custom rules, doctor diagnostics\n");
|
|
38995
38979
|
console.log(`${pc5.blue("INDIVIDUAL")} - $49 one-time`);
|
|
38996
|
-
console.log("
|
|
38980
|
+
console.log(" + Zod v3 \u2192 v4");
|
|
38997
38981
|
console.log(" HTML reports, git integration, advanced analysis");
|
|
38998
38982
|
console.log(" Risk scoring, CSV export, compare command\n");
|
|
38999
38983
|
console.log(`${pc5.magenta("PRO")} - $149 one-time`);
|
package/dist/index.cjs
CHANGED
|
@@ -33779,7 +33779,6 @@ var TIER_FEATURES = {
|
|
|
33779
33779
|
"free"
|
|
33780
33780
|
/* FREE */
|
|
33781
33781
|
]: {
|
|
33782
|
-
maxFiles: 10,
|
|
33783
33782
|
migrations: ["yup->zod", "joi->zod"],
|
|
33784
33783
|
devices: 1,
|
|
33785
33784
|
ciSupport: false,
|
|
@@ -33812,7 +33811,6 @@ var TIER_FEATURES = {
|
|
|
33812
33811
|
"individual"
|
|
33813
33812
|
/* INDIVIDUAL */
|
|
33814
33813
|
]: {
|
|
33815
|
-
maxFiles: Infinity,
|
|
33816
33814
|
migrations: ["yup->zod", "joi->zod", "zod-v3->v4"],
|
|
33817
33815
|
devices: 1,
|
|
33818
33816
|
ciSupport: false,
|
|
@@ -33845,7 +33843,6 @@ var TIER_FEATURES = {
|
|
|
33845
33843
|
"pro"
|
|
33846
33844
|
/* PRO */
|
|
33847
33845
|
]: {
|
|
33848
|
-
maxFiles: Infinity,
|
|
33849
33846
|
migrations: [
|
|
33850
33847
|
"yup->zod",
|
|
33851
33848
|
"joi->zod",
|
|
@@ -33892,7 +33889,6 @@ var TIER_FEATURES = {
|
|
|
33892
33889
|
"team"
|
|
33893
33890
|
/* TEAM */
|
|
33894
33891
|
]: {
|
|
33895
|
-
maxFiles: Infinity,
|
|
33896
33892
|
migrations: [
|
|
33897
33893
|
"yup->zod",
|
|
33898
33894
|
"joi->zod",
|
package/dist/index.js
CHANGED
|
@@ -33730,7 +33730,6 @@ var TIER_FEATURES = {
|
|
|
33730
33730
|
"free"
|
|
33731
33731
|
/* FREE */
|
|
33732
33732
|
]: {
|
|
33733
|
-
maxFiles: 10,
|
|
33734
33733
|
migrations: ["yup->zod", "joi->zod"],
|
|
33735
33734
|
devices: 1,
|
|
33736
33735
|
ciSupport: false,
|
|
@@ -33763,7 +33762,6 @@ var TIER_FEATURES = {
|
|
|
33763
33762
|
"individual"
|
|
33764
33763
|
/* INDIVIDUAL */
|
|
33765
33764
|
]: {
|
|
33766
|
-
maxFiles: Infinity,
|
|
33767
33765
|
migrations: ["yup->zod", "joi->zod", "zod-v3->v4"],
|
|
33768
33766
|
devices: 1,
|
|
33769
33767
|
ciSupport: false,
|
|
@@ -33796,7 +33794,6 @@ var TIER_FEATURES = {
|
|
|
33796
33794
|
"pro"
|
|
33797
33795
|
/* PRO */
|
|
33798
33796
|
]: {
|
|
33799
|
-
maxFiles: Infinity,
|
|
33800
33797
|
migrations: [
|
|
33801
33798
|
"yup->zod",
|
|
33802
33799
|
"joi->zod",
|
|
@@ -33843,7 +33840,6 @@ var TIER_FEATURES = {
|
|
|
33843
33840
|
"team"
|
|
33844
33841
|
/* TEAM */
|
|
33845
33842
|
]: {
|
|
33846
|
-
maxFiles: Infinity,
|
|
33847
33843
|
migrations: [
|
|
33848
33844
|
"yup->zod",
|
|
33849
33845
|
"joi->zod",
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "schemashift-cli",
|
|
3
|
-
"version": "0.
|
|
3
|
+
"version": "0.15.0",
|
|
4
4
|
"description": "TypeScript schema migration CLI - migrate between Zod, Yup, Joi, and more",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"bin": {
|
|
@@ -44,7 +44,8 @@
|
|
|
44
44
|
},
|
|
45
45
|
"repository": {
|
|
46
46
|
"type": "git",
|
|
47
|
-
"url": "https://github.com/jdmay2/schemashift"
|
|
47
|
+
"url": "https://github.com/jdmay2/schemashift",
|
|
48
|
+
"directory": "packages/cli"
|
|
48
49
|
},
|
|
49
50
|
"author": "Joseph May",
|
|
50
51
|
"license": "MIT",
|
|
@@ -52,15 +53,15 @@
|
|
|
52
53
|
"node": ">=22.0.0"
|
|
53
54
|
},
|
|
54
55
|
"dependencies": {
|
|
55
|
-
"@schemashift/core": "0.
|
|
56
|
-
"@schemashift/io-ts-effect": "0.
|
|
57
|
-
"@schemashift/io-ts-zod": "0.
|
|
58
|
-
"@schemashift/joi-zod": "0.
|
|
59
|
-
"@schemashift/yup-zod": "0.
|
|
60
|
-
"@schemashift/zod-arktype": "0.
|
|
61
|
-
"@schemashift/zod-superstruct": "0.
|
|
62
|
-
"@schemashift/zod-valibot": "0.
|
|
63
|
-
"@schemashift/zod-v3-v4": "0.
|
|
56
|
+
"@schemashift/core": "0.14.0",
|
|
57
|
+
"@schemashift/io-ts-effect": "0.14.0",
|
|
58
|
+
"@schemashift/io-ts-zod": "0.14.0",
|
|
59
|
+
"@schemashift/joi-zod": "0.14.0",
|
|
60
|
+
"@schemashift/yup-zod": "0.14.0",
|
|
61
|
+
"@schemashift/zod-arktype": "0.14.0",
|
|
62
|
+
"@schemashift/zod-superstruct": "0.14.0",
|
|
63
|
+
"@schemashift/zod-valibot": "0.14.0",
|
|
64
|
+
"@schemashift/zod-v3-v4": "0.14.0",
|
|
64
65
|
"commander": "14.0.3",
|
|
65
66
|
"cosmiconfig": "9.0.0",
|
|
66
67
|
"glob": "13.0.0",
|
|
@@ -69,7 +70,7 @@
|
|
|
69
70
|
"picocolors": "1.1.1"
|
|
70
71
|
},
|
|
71
72
|
"devDependencies": {
|
|
72
|
-
"@schemashift/license": "0.
|
|
73
|
+
"@schemashift/license": "0.13.0"
|
|
73
74
|
},
|
|
74
75
|
"publishConfig": {
|
|
75
76
|
"access": "public"
|