@wix/create-new 0.0.32 → 0.0.34
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/build/{chunk-4P3PPFXH.js → chunk-2HGCGDHC.js} +37 -24
- package/build/chunk-2HGCGDHC.js.map +1 -0
- package/build/{generator-L3CXBMWA.js → generator-2M4JKPFM.js} +2 -2
- package/build/index.js +746 -520
- package/build/index.js.map +1 -1
- package/package.json +2 -2
- package/templates/app/blank/package.json.ejs +1 -1
- package/build/chunk-4P3PPFXH.js.map +0 -1
- /package/build/{generator-L3CXBMWA.js.map → generator-2M4JKPFM.js.map} +0 -0
|
@@ -711,12 +711,12 @@ var require_isType = __commonJS({
|
|
|
711
711
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
712
712
|
exports.isTypeImpl = void 0;
|
|
713
713
|
function isTypeImpl(key) {
|
|
714
|
-
function
|
|
714
|
+
function isType4(instanceOrType, type) {
|
|
715
715
|
if (instanceOrType != void 0) {
|
|
716
716
|
if (typeof instanceOrType === "function" || typeof instanceOrType === "string") {
|
|
717
717
|
const typeArg = instanceOrType;
|
|
718
718
|
const typeStr = typeof typeArg === "string" ? typeArg : typeArg.output.type;
|
|
719
|
-
return (o) =>
|
|
719
|
+
return (o) => isType4(o, typeStr);
|
|
720
720
|
} else {
|
|
721
721
|
const instance = instanceOrType;
|
|
722
722
|
const typeStr = typeof type === "string" ? type : type.output.type;
|
|
@@ -726,7 +726,7 @@ var require_isType = __commonJS({
|
|
|
726
726
|
return false;
|
|
727
727
|
}
|
|
728
728
|
}
|
|
729
|
-
return { isType:
|
|
729
|
+
return { isType: isType4 };
|
|
730
730
|
}
|
|
731
731
|
exports.isTypeImpl = isTypeImpl;
|
|
732
732
|
}
|
|
@@ -993,13 +993,13 @@ var require_remote = __commonJS({
|
|
|
993
993
|
CompareResult2[CompareResult2["Greater"] = 1] = "Greater";
|
|
994
994
|
})(CompareResult = exports.CompareResult || (exports.CompareResult = {}));
|
|
995
995
|
function remoteImpl(key) {
|
|
996
|
-
const { isType:
|
|
996
|
+
const { isType: isType4 } = (0, isType_1.isTypeImpl)(key);
|
|
997
997
|
const { match } = (0, match_1.matchImpl)(key);
|
|
998
998
|
const { variantList } = (0, variant_1.variantImpl)(key);
|
|
999
999
|
function isFunctions(vmod) {
|
|
1000
1000
|
const keys = Object.keys(vmod);
|
|
1001
1001
|
return keys.reduce((acc, key2) => {
|
|
1002
|
-
return Object.assign(Object.assign({}, acc), { [key2]:
|
|
1002
|
+
return Object.assign(Object.assign({}, acc), { [key2]: isType4(key2) });
|
|
1003
1003
|
}, {});
|
|
1004
1004
|
}
|
|
1005
1005
|
function remote(vmod) {
|
|
@@ -1267,11 +1267,11 @@ var require_cosmos = __commonJS({
|
|
|
1267
1267
|
var typed_1 = require_typed();
|
|
1268
1268
|
var matcher_1 = require_matcher();
|
|
1269
1269
|
function variantCosmos({ key }) {
|
|
1270
|
-
const { isType:
|
|
1270
|
+
const { isType: isType4 } = (0, isType_1.isTypeImpl)(key);
|
|
1271
1271
|
const { flags } = (0, flags_1.flagsImpl)(key);
|
|
1272
1272
|
return Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign(Object.assign({
|
|
1273
1273
|
key,
|
|
1274
|
-
isType:
|
|
1274
|
+
isType: isType4,
|
|
1275
1275
|
flags
|
|
1276
1276
|
}, (0, isOfVariant_1.isOfVariantImpl)(key)), (0, match_1.matchImpl)(key)), (0, matcher_1.matcherImpl)(key)), (0, remote_1.remoteImpl)(key)), (0, typed_1.typedImpl)(key)), (0, types_1.typesImpl)(key)), (0, variant_1.variantImpl)(key));
|
|
1277
1277
|
}
|
|
@@ -16431,6 +16431,7 @@ var CliSystemErrorCode = (0, import_variant.variant)({
|
|
|
16431
16431
|
FailedToParseNextVersion: (0, import_variant.fields)(),
|
|
16432
16432
|
FailedToDistributeClientManifestUpdate: {},
|
|
16433
16433
|
FailedToCreateRoutesWithMetaSiteUrl: {},
|
|
16434
|
+
FailedToUpdateExternalSiteUrl: {},
|
|
16434
16435
|
FailedToGetGitHubOnboardingStatus: (0, import_variant.fields)(),
|
|
16435
16436
|
FailedToInitGitHubRepository: (0, import_variant.fields)()
|
|
16436
16437
|
});
|
|
@@ -16608,6 +16609,16 @@ function normalizeError(error) {
|
|
|
16608
16609
|
return firstUserError ?? cliError;
|
|
16609
16610
|
}
|
|
16610
16611
|
|
|
16612
|
+
// ../cli-error/src/get-unknown-failure-message.ts
|
|
16613
|
+
init_esm_shims();
|
|
16614
|
+
var import_variant4 = __toESM(require_lib(), 1);
|
|
16615
|
+
function getUnknownFailureMessage(error) {
|
|
16616
|
+
if (isCliSystemError(error) && (0, import_variant4.isType)(error.cliCode, CliSystemErrorCode.UnknownFailure) && error.cliCode.error instanceof Error && typeof error.cliCode.error.message === "string") {
|
|
16617
|
+
return error.cliCode.error.message;
|
|
16618
|
+
}
|
|
16619
|
+
return error.message;
|
|
16620
|
+
}
|
|
16621
|
+
|
|
16611
16622
|
// ../cli-fs/src/index.ts
|
|
16612
16623
|
var import_dotenv = __toESM(require_main(), 1);
|
|
16613
16624
|
|
|
@@ -16729,7 +16740,7 @@ async function updateEnvFile(target, variables) {
|
|
|
16729
16740
|
}
|
|
16730
16741
|
|
|
16731
16742
|
// ../package-manager/src/repo-type.ts
|
|
16732
|
-
var
|
|
16743
|
+
var import_variant5 = __toESM(require_lib(), 1);
|
|
16733
16744
|
import { join as join2 } from "node:path";
|
|
16734
16745
|
|
|
16735
16746
|
// ../package-manager/src/git-service.ts
|
|
@@ -18462,10 +18473,10 @@ async function gitGetUserInfo(cwd) {
|
|
|
18462
18473
|
}
|
|
18463
18474
|
|
|
18464
18475
|
// ../package-manager/src/repo-type.ts
|
|
18465
|
-
var RepoType = (0,
|
|
18476
|
+
var RepoType = (0, import_variant5.variant)({
|
|
18466
18477
|
None: {},
|
|
18467
|
-
Polyrepo: (0,
|
|
18468
|
-
Monorepo: (0,
|
|
18478
|
+
Polyrepo: (0, import_variant5.fields)(),
|
|
18479
|
+
Monorepo: (0, import_variant5.fields)()
|
|
18469
18480
|
});
|
|
18470
18481
|
async function getRepoType(targetParentFolder) {
|
|
18471
18482
|
if (!await isInsideGitRepo(targetParentFolder)) {
|
|
@@ -18489,11 +18500,11 @@ async function isUsingWorkspaces(rootDir) {
|
|
|
18489
18500
|
init_esm_shims();
|
|
18490
18501
|
import { env } from "node:process";
|
|
18491
18502
|
import { join as join4 } from "node:path";
|
|
18492
|
-
var
|
|
18503
|
+
var import_variant8 = __toESM(require_lib(), 1);
|
|
18493
18504
|
|
|
18494
18505
|
// ../package-manager/src/adapters/npm.ts
|
|
18495
18506
|
init_esm_shims();
|
|
18496
|
-
var
|
|
18507
|
+
var import_variant6 = __toESM(require_lib(), 1);
|
|
18497
18508
|
var NPM = class {
|
|
18498
18509
|
constructor(repoType) {
|
|
18499
18510
|
this.repoType = repoType;
|
|
@@ -18515,7 +18526,7 @@ var NPM = class {
|
|
|
18515
18526
|
};
|
|
18516
18527
|
}
|
|
18517
18528
|
async setup(_cwd) {
|
|
18518
|
-
if ((0,
|
|
18529
|
+
if ((0, import_variant6.isType)(this.repoType, RepoType.Monorepo)) {
|
|
18519
18530
|
throw new CliError({
|
|
18520
18531
|
code: CliErrorCode.UnsupportedPackageManagerWorkspaces({
|
|
18521
18532
|
packageManagerName: this.name
|
|
@@ -18561,7 +18572,7 @@ var NPM = class {
|
|
|
18561
18572
|
|
|
18562
18573
|
// ../package-manager/src/adapters/yarn.ts
|
|
18563
18574
|
init_esm_shims();
|
|
18564
|
-
var
|
|
18575
|
+
var import_variant7 = __toESM(require_lib(), 1);
|
|
18565
18576
|
import { join as join3, relative as relative2 } from "node:path";
|
|
18566
18577
|
import { EOL as EOL2 } from "node:os";
|
|
18567
18578
|
import { writeFile as writeFile2 } from "node:fs/promises";
|
|
@@ -18590,7 +18601,7 @@ var Yarn = class {
|
|
|
18590
18601
|
};
|
|
18591
18602
|
}
|
|
18592
18603
|
async setup(packageFolder) {
|
|
18593
|
-
return (0,
|
|
18604
|
+
return (0, import_variant7.matcher)(this.repoType).when(["None", "Polyrepo"], async () => {
|
|
18594
18605
|
if (this.name === "yarn-berry") {
|
|
18595
18606
|
await writeFile2(join3(packageFolder, "yarn.lock"), "");
|
|
18596
18607
|
}
|
|
@@ -18729,7 +18740,7 @@ async function getPackageManagerName(repoType) {
|
|
|
18729
18740
|
cause: null
|
|
18730
18741
|
});
|
|
18731
18742
|
};
|
|
18732
|
-
return (0,
|
|
18743
|
+
return (0, import_variant8.matcher)(repoType).when(RepoType.None, getByEnv).when(
|
|
18733
18744
|
[RepoType.Polyrepo, RepoType.Monorepo],
|
|
18734
18745
|
async ({ rootDir }) => {
|
|
18735
18746
|
const [hasYarnRc, hasYarnLock, hasPackageLock] = await Promise.all([
|
|
@@ -18953,7 +18964,7 @@ var import_fast_glob2 = __toESM(require_out4(), 1);
|
|
|
18953
18964
|
init_esm_shims();
|
|
18954
18965
|
import fs from "node:fs";
|
|
18955
18966
|
import fsPromises from "node:fs/promises";
|
|
18956
|
-
async function
|
|
18967
|
+
async function isType3(fsStatType, statsMethodName, filePath) {
|
|
18957
18968
|
if (typeof filePath !== "string") {
|
|
18958
18969
|
throw new TypeError(`Expected a string, got ${typeof filePath}`);
|
|
18959
18970
|
}
|
|
@@ -18980,9 +18991,9 @@ function isTypeSync(fsStatType, statsMethodName, filePath) {
|
|
|
18980
18991
|
throw error;
|
|
18981
18992
|
}
|
|
18982
18993
|
}
|
|
18983
|
-
var isFile =
|
|
18984
|
-
var isDirectory =
|
|
18985
|
-
var isSymlink =
|
|
18994
|
+
var isFile = isType3.bind(void 0, "stat", "isFile");
|
|
18995
|
+
var isDirectory = isType3.bind(void 0, "stat", "isDirectory");
|
|
18996
|
+
var isSymlink = isType3.bind(void 0, "lstat", "isSymbolicLink");
|
|
18986
18997
|
var isFileSync = isTypeSync.bind(void 0, "statSync", "isFile");
|
|
18987
18998
|
var isDirectorySync = isTypeSync.bind(void 0, "statSync", "isDirectory");
|
|
18988
18999
|
var isSymlinkSync = isTypeSync.bind(void 0, "lstatSync", "isSymbolicLink");
|
|
@@ -19350,7 +19361,7 @@ init_esm_shims();
|
|
|
19350
19361
|
// ../cli-astro-definitions/src/definitions.ts
|
|
19351
19362
|
init_esm_shims();
|
|
19352
19363
|
import { join as join5 } from "node:path";
|
|
19353
|
-
var
|
|
19364
|
+
var import_variant9 = __toESM(require_lib(), 1);
|
|
19354
19365
|
var wixAstroSiteConfigSchema = zod_default.object({
|
|
19355
19366
|
$schema: zod_default.string().optional(),
|
|
19356
19367
|
projectType: zod_default.literal("Site").optional().default("Site"),
|
|
@@ -19408,11 +19419,12 @@ function getEnvFilePath(projectFolder) {
|
|
|
19408
19419
|
}
|
|
19409
19420
|
var MULTILINGUAL_DIR = join5(GIT_IGNORED_DIR, "multilingual");
|
|
19410
19421
|
var TRANSLATIONS_DIR = join5(MULTILINGUAL_DIR, "translations");
|
|
19411
|
-
var PlatformType = (0,
|
|
19422
|
+
var PlatformType = (0, import_variant9.variant)({
|
|
19412
19423
|
Site: {},
|
|
19413
19424
|
Editor: {},
|
|
19414
19425
|
Dashboard: {}
|
|
19415
19426
|
});
|
|
19427
|
+
var DEV_LOG_PATH = join5(GIT_IGNORED_DIR, "dev.log");
|
|
19416
19428
|
|
|
19417
19429
|
// ../../node_modules/tempy/index.js
|
|
19418
19430
|
init_esm_shims();
|
|
@@ -19570,6 +19582,7 @@ export {
|
|
|
19570
19582
|
isCliError,
|
|
19571
19583
|
isCliSystemError,
|
|
19572
19584
|
normalizeError,
|
|
19585
|
+
getUnknownFailureMessage,
|
|
19573
19586
|
external_exports,
|
|
19574
19587
|
zod_default,
|
|
19575
19588
|
getTestOverrides,
|
|
@@ -19664,4 +19677,4 @@ is-git-url/index.js:
|
|
|
19664
19677
|
* Released under the MIT License.
|
|
19665
19678
|
*)
|
|
19666
19679
|
*/
|
|
19667
|
-
//# sourceMappingURL=chunk-
|
|
19680
|
+
//# sourceMappingURL=chunk-2HGCGDHC.js.map
|