@wirechunk/cli 0.0.8 → 0.0.9
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/main.js +25 -13
- package/package.json +1 -1
package/build/main.js
CHANGED
|
@@ -26588,6 +26588,7 @@ const grantAllUserPlatformPermissions = async ({
|
|
|
26588
26588
|
)} on conflict ("platformAdminId", "object", "action") do nothing`
|
|
26589
26589
|
);
|
|
26590
26590
|
};
|
|
26591
|
+
const devAdminPlatformId = "ths9gw8";
|
|
26591
26592
|
const devUserEmail = "dev@example.com";
|
|
26592
26593
|
const devUserPassword = "password00";
|
|
26593
26594
|
const platformHandleAvailable = async (handle, db) => !await db.maybeOne(
|
|
@@ -26671,19 +26672,30 @@ const bootstrap = async (opts, env2) => {
|
|
|
26671
26672
|
error: `Domain "${adminSiteDomain}" is already in use by the platform with ID ${existingSiteForDomain.platformId}`
|
|
26672
26673
|
};
|
|
26673
26674
|
}
|
|
26674
|
-
const
|
|
26675
|
-
|
|
26676
|
-
|
|
26677
|
-
|
|
26678
|
-
|
|
26679
|
-
|
|
26680
|
-
|
|
26681
|
-
|
|
26682
|
-
|
|
26683
|
-
|
|
26684
|
-
|
|
26685
|
-
|
|
26686
|
-
|
|
26675
|
+
const insertPlatformQuery = opts.dev ? sql.type(stringIdSelectSchema)`
|
|
26676
|
+
insert into "Platforms" (
|
|
26677
|
+
"id",
|
|
26678
|
+
"handle",
|
|
26679
|
+
"name"
|
|
26680
|
+
)
|
|
26681
|
+
values (
|
|
26682
|
+
${devAdminPlatformId},
|
|
26683
|
+
${handle},
|
|
26684
|
+
${name}
|
|
26685
|
+
)
|
|
26686
|
+
returning "id"
|
|
26687
|
+
` : sql.type(stringIdSelectSchema)`
|
|
26688
|
+
insert into "Platforms" (
|
|
26689
|
+
"handle",
|
|
26690
|
+
"name"
|
|
26691
|
+
)
|
|
26692
|
+
values (
|
|
26693
|
+
${handle},
|
|
26694
|
+
${name}
|
|
26695
|
+
)
|
|
26696
|
+
returning "id"
|
|
26697
|
+
`;
|
|
26698
|
+
const platform = await db2.one(insertPlatformQuery);
|
|
26687
26699
|
const adminSiteId = cleanSmallId();
|
|
26688
26700
|
await db2.query(
|
|
26689
26701
|
sql.type(voidSelectSchema)`
|