@mediamonks/canopy-cli 0.7.60 → 0.7.61
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/dist/{deploy-Bp5DMp_U.mjs → deploy-Qe5jRWpi.mjs} +12 -1
- package/dist/docs/cli-deploy.md +1 -1
- package/dist/{docs-DH1bWRny.mjs → docs-Cvrkba0X.mjs} +1 -1
- package/dist/{feedback-Q0UhJ6gI.mjs → feedback-DqZqxMQr.mjs} +1 -1
- package/dist/index.mjs +10 -10
- package/dist/{mcp-CmfLQ9Vo.mjs → mcp-CkCiu-1J.mjs} +1 -1
- package/dist/{package-CJvO8vJf.mjs → package-CyuzTQmN.mjs} +1 -1
- package/dist/{skill-CpnX4oLF.mjs → skill-CCz7sQ1t.mjs} +1 -1
- package/dist/{upgrade-KYHqugVq.mjs → upgrade-vJEkO28k.mjs} +1 -1
- package/package.json +1 -1
|
@@ -165,6 +165,8 @@ const MEDIA_EXTENSIONS = /* @__PURE__ */ new Set([
|
|
|
165
165
|
"json",
|
|
166
166
|
"csv",
|
|
167
167
|
"txt",
|
|
168
|
+
"vtt",
|
|
169
|
+
"srt",
|
|
168
170
|
"png",
|
|
169
171
|
"jpg",
|
|
170
172
|
"jpeg",
|
|
@@ -174,14 +176,23 @@ const MEDIA_EXTENSIONS = /* @__PURE__ */ new Set([
|
|
|
174
176
|
"ico",
|
|
175
177
|
"mp4",
|
|
176
178
|
"webm",
|
|
179
|
+
"m4v",
|
|
180
|
+
"mov",
|
|
181
|
+
"ogv",
|
|
177
182
|
"mp3",
|
|
178
183
|
"wav",
|
|
179
184
|
"ogg",
|
|
180
185
|
"m4a",
|
|
186
|
+
"aac",
|
|
187
|
+
"flac",
|
|
188
|
+
"opus",
|
|
181
189
|
"woff",
|
|
182
190
|
"woff2",
|
|
191
|
+
"ttf",
|
|
192
|
+
"otf",
|
|
183
193
|
"glb",
|
|
184
194
|
"gltf",
|
|
195
|
+
"usdz",
|
|
185
196
|
"bin"
|
|
186
197
|
]);
|
|
187
198
|
function isMediaFile(path) {
|
|
@@ -520,7 +531,7 @@ const deployCommand = defineCommand({
|
|
|
520
531
|
for (const folder of mediaFolders) if (!media.some((f) => f.path.startsWith(folder))) p.log.warn(`canopy.json "media": ${folder} is not in the build output; nothing to upload from it.`);
|
|
521
532
|
const notMedia = media.filter((f) => !isMediaFile(f.path)).map((f) => f.path);
|
|
522
533
|
if (notMedia.length > 0) throw new Error([
|
|
523
|
-
"Site media holds data and media files only (JSON, CSV, text, images, video, audio, fonts, 3D models). These can't be media:",
|
|
534
|
+
"Site media holds data and media files only (JSON, CSV, text, captions, images, video, audio, fonts, 3D models). These can't be media:",
|
|
524
535
|
...notMedia.slice(0, 20).map((path) => ` ${path}`),
|
|
525
536
|
...notMedia.length > 20 ? [` … and ${notMedia.length - 20} more`] : [],
|
|
526
537
|
"Move them out of the media folders, or take the folder out of canopy.json \"media\"."
|
package/dist/docs/cli-deploy.md
CHANGED
|
@@ -46,7 +46,7 @@ A folder of large data or media that rarely changes, such as Storybook mock data
|
|
|
46
46
|
}
|
|
47
47
|
```
|
|
48
48
|
|
|
49
|
-
The folders are paths inside the build output. Their files keep their URLs (`/mocks/users.json`), and don't count toward the deploy limit. They may hold data and media only: JSON, CSV, text, images, video, audio, fonts and 3D models. A folder with HTML, JavaScript, CSS or
|
|
49
|
+
The folders are paths inside the build output. Their files keep their URLs (`/mocks/users.json`), and don't count toward the deploy limit. They may hold data and media only: JSON, CSV, text, captions, images, video, audio, fonts and 3D models. A folder with HTML, JavaScript, CSS, SVG or PDF in it is refused before anything uploads. **Media is not versioned:** a rollback or a pinned version serves the current files, and it is shared with the staging channel.
|
|
50
50
|
|
|
51
51
|
The CLI suggests folders for you. When the version reaches 30% of the deploy limit, the deploy ends with a hint naming the folders that could move and the exact `"media"` line to add. When it is over the limit, the refusal names the folders that would bring it under. The CLI never edits `canopy.json` itself. See [Site media](https://docs.canopy.website/guides/static-serving#site-media) for limits and details.
|
|
52
52
|
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { t as version } from "./package-
|
|
1
|
+
import { t as version } from "./package-CyuzTQmN.mjs";
|
|
2
2
|
import { r as siteConfig } from "./site-Bz-fEyKS.mjs";
|
|
3
3
|
import { i as latestKnownVersion, r as compareSemver } from "./version-check-CcsA1QjI.mjs";
|
|
4
4
|
import { n as agentHeaders } from "./api-CpG-9WSe.mjs";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { t as version } from "./package-
|
|
1
|
+
import { t as version } from "./package-CyuzTQmN.mjs";
|
|
2
2
|
import { f as resolveProject, g as tryResolveProject, h as tryReadCanopyJson, l as projectDirArgs, r as siteConfig } from "./site-Bz-fEyKS.mjs";
|
|
3
3
|
import { a as apiRequest, c as credentials, i as apiDownload, o as apiUpload, s as commonHeaders } from "./api-CpG-9WSe.mjs";
|
|
4
4
|
import { i as reportErrors, n as formatDateTime } from "./ui-BUeiY_zZ.mjs";
|
package/dist/index.mjs
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
-
import { t as version } from "./package-
|
|
2
|
+
import { t as version } from "./package-CyuzTQmN.mjs";
|
|
3
3
|
import { i as siteHeaderLine, n as setInvocationProfile } from "./site-Bz-fEyKS.mjs";
|
|
4
4
|
import { a as notifyOfUpdate, o as runRefresh } from "./version-check-CcsA1QjI.mjs";
|
|
5
5
|
import { defineCommand, runMain } from "citty";
|
|
@@ -60,11 +60,11 @@ const main = defineCommand({
|
|
|
60
60
|
delete: () => import("./projects-DCFn4zcq.mjs").then((m) => m.deleteCommand),
|
|
61
61
|
rename: () => import("./rename-OeOI97da.mjs").then((m) => m.renameCommand),
|
|
62
62
|
dev: () => import("./dev-pj6lLjMR.mjs").then((m) => m.devCommand),
|
|
63
|
-
deploy: () => import("./deploy-
|
|
64
|
-
promote: () => import("./deploy-
|
|
63
|
+
deploy: () => import("./deploy-Qe5jRWpi.mjs").then((m) => m.deployCommand),
|
|
64
|
+
promote: () => import("./deploy-Qe5jRWpi.mjs").then((m) => m.promoteCommand),
|
|
65
65
|
staging: () => import("./staging-D6-Ojy39.mjs").then((m) => m.stagingCommand),
|
|
66
|
-
rollback: () => import("./deploy-
|
|
67
|
-
download: () => import("./deploy-
|
|
66
|
+
rollback: () => import("./deploy-Qe5jRWpi.mjs").then((m) => m.rollbackCommand),
|
|
67
|
+
download: () => import("./deploy-Qe5jRWpi.mjs").then((m) => m.downloadCommand),
|
|
68
68
|
versions: () => import("./versions-C204ivt9.mjs").then((m) => m.versionsCommand),
|
|
69
69
|
token: () => import("./token-yAj7pF78.mjs").then((m) => m.tokenCommand),
|
|
70
70
|
egress: () => import("./egress-Dwq-d6cB.mjs").then((m) => m.egressCommand),
|
|
@@ -74,18 +74,18 @@ const main = defineCommand({
|
|
|
74
74
|
roles: () => import("./roles-2Pkqiwrx.mjs").then((m) => m.rolesCommand),
|
|
75
75
|
members: () => import("./roles-2Pkqiwrx.mjs").then((m) => m.membersCommand),
|
|
76
76
|
schedule: () => import("./schedule-Cy-7IFy5.mjs").then((m) => m.scheduleCommand),
|
|
77
|
-
feedback: () => import("./feedback-
|
|
77
|
+
feedback: () => import("./feedback-DqZqxMQr.mjs").then((m) => m.feedbackCommand),
|
|
78
78
|
db: () => import("./db-DIxujtt1.mjs").then((m) => m.dbCommand),
|
|
79
79
|
files: () => import("./files-CUPtGcuZ.mjs").then((m) => m.filesCommand),
|
|
80
80
|
usage: () => import("./usage-BXPm04tk.mjs").then((m) => m.usageCommand),
|
|
81
81
|
ai: () => import("./ai-4Mr9FbLU.mjs").then((m) => m.aiCommand),
|
|
82
82
|
open: () => import("./open-5JLHiz_J.mjs").then((m) => m.openCommand),
|
|
83
83
|
browse: () => import("./browse-BegddW9V.mjs").then((m) => m.browseCommand),
|
|
84
|
-
docs: () => import("./docs-
|
|
85
|
-
skill: () => import("./skill-
|
|
86
|
-
upgrade: () => import("./upgrade-
|
|
84
|
+
docs: () => import("./docs-Cvrkba0X.mjs").then((m) => m.docsCommand),
|
|
85
|
+
skill: () => import("./skill-CCz7sQ1t.mjs").then((m) => m.skillCommand),
|
|
86
|
+
upgrade: () => import("./upgrade-vJEkO28k.mjs").then((m) => m.upgradeCommand),
|
|
87
87
|
logs: () => import("./logs-BwqG7lYU.mjs").then((m) => m.logsCommand),
|
|
88
|
-
mcp: () => import("./mcp-
|
|
88
|
+
mcp: () => import("./mcp-CkCiu-1J.mjs").then((m) => m.mcpCommand),
|
|
89
89
|
repo: () => import("./repo-BW7dDQZL.mjs").then((m) => m.repoCommand),
|
|
90
90
|
template: () => import("./project-template-xNjGs9ty.mjs").then((m) => m.templateCommand),
|
|
91
91
|
audience: () => import("./audience-BXXdvGC_.mjs").then((m) => m.audienceCommand)
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { t as version } from "./package-
|
|
1
|
+
import { t as version } from "./package-CyuzTQmN.mjs";
|
|
2
2
|
import { d as projectUrl, g as tryResolveProject, m as stagingUrl, r as siteConfig } from "./site-Bz-fEyKS.mjs";
|
|
3
3
|
import { a as apiRequest, f as noticeRenamesOnly, l as currentSlug, t as ApiError } from "./api-CpG-9WSe.mjs";
|
|
4
4
|
import { t as liveDevServer } from "./dev-server-file-Dk9pk4AR.mjs";
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { t as version } from "./package-
|
|
1
|
+
import { t as version } from "./package-CyuzTQmN.mjs";
|
|
2
2
|
import { i as reportErrors } from "./ui-BUeiY_zZ.mjs";
|
|
3
3
|
import { defineCommand } from "citty";
|
|
4
4
|
import { cpSync, existsSync, mkdirSync, rmSync, symlinkSync, writeFileSync } from "node:fs";
|
|
@@ -112,7 +112,7 @@ const upgradeCommand = defineCommand({
|
|
|
112
112
|
const spec = `${PACKAGE_NAME}@${args.version ?? "latest"}`;
|
|
113
113
|
const command = pmCommand(pm);
|
|
114
114
|
const cmd = installArgs(pm, spec);
|
|
115
|
-
const { skillInstalled } = await import("./skill-
|
|
115
|
+
const { skillInstalled } = await import("./skill-CCz7sQ1t.mjs");
|
|
116
116
|
const { homedir } = await import("node:os");
|
|
117
117
|
const refreshGlobal = skillInstalled(homedir());
|
|
118
118
|
const refreshRepo = process.cwd() !== homedir() && skillInstalled(process.cwd());
|