juicyjuicy 0.6.0 → 0.7.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/dist/index.js
CHANGED
|
@@ -19806,6 +19806,23 @@ function date4(params) {
|
|
|
19806
19806
|
return _coercedDate(ZodDate, params);
|
|
19807
19807
|
}
|
|
19808
19808
|
|
|
19809
|
+
// ../shared/src/cli.ts
|
|
19810
|
+
var CLI_RELEASE = "0.7.0";
|
|
19811
|
+
function cliCommand(args) {
|
|
19812
|
+
return `npx -y juicyjuicy@${CLI_RELEASE} ${args}`;
|
|
19813
|
+
}
|
|
19814
|
+
var CLI_UPDATE_COMMAND = cliCommand("setup --yes");
|
|
19815
|
+
function compareVersions(a2, b) {
|
|
19816
|
+
const parts = (version2) => version2.split("-")[0]?.split(".").map((part) => Number.parseInt(part, 10) || 0) ?? [];
|
|
19817
|
+
const left = parts(a2);
|
|
19818
|
+
const right = parts(b);
|
|
19819
|
+
for (let i2 = 0; i2 < Math.max(left.length, right.length); i2++) {
|
|
19820
|
+
const difference = (left[i2] ?? 0) - (right[i2] ?? 0);
|
|
19821
|
+
if (difference !== 0) return Math.sign(difference);
|
|
19822
|
+
}
|
|
19823
|
+
return 0;
|
|
19824
|
+
}
|
|
19825
|
+
|
|
19809
19826
|
// ../shared/src/limits.ts
|
|
19810
19827
|
var MB = 1024 * 1024;
|
|
19811
19828
|
var LIMITS = {
|
|
@@ -20074,7 +20091,7 @@ var startVersionRequestSchema = external_exports.object({
|
|
|
20074
20091
|
size: external_exports.number(),
|
|
20075
20092
|
/** Hex SHA-256, required for every file; R2 refuses an upload that doesn't match it (D15). */
|
|
20076
20093
|
sha256: external_exports.string({
|
|
20077
|
-
error:
|
|
20094
|
+
error: `Every file needs its sha256. Update the CLI: ${CLI_UPDATE_COMMAND}`
|
|
20078
20095
|
}).regex(SHA256_PATTERN, "sha256 must be 64 lowercase hex digits")
|
|
20079
20096
|
})
|
|
20080
20097
|
).max(LIMITS.maxFiles * 4),
|
|
@@ -20220,6 +20237,7 @@ var GAME_FEATURES = [
|
|
|
20220
20237
|
{
|
|
20221
20238
|
id: "browser-menu",
|
|
20222
20239
|
name: "Browser-friendly menu",
|
|
20240
|
+
summary: "Pause works in fullscreen: a key other than Esc, or an on-screen button.",
|
|
20223
20241
|
adds: "The game's menu or pause opens with a key that isn't Esc (like P) or an on-screen button, and there's no Quit button, or Quit says progress is saved and the tab can be closed.",
|
|
20224
20242
|
why: "In a browser, Esc leaves fullscreen before the game sees it, so a menu on Esc alone throws players out of fullscreen instead of pausing, and a Quit that does nothing looks broken.",
|
|
20225
20243
|
detection: { kind: "declared" },
|
|
@@ -20231,6 +20249,7 @@ var GAME_FEATURES = [
|
|
|
20231
20249
|
{
|
|
20232
20250
|
id: "cloud-saves",
|
|
20233
20251
|
name: "Cloud saves",
|
|
20252
|
+
summary: "Progress follows signed-in players to any browser.",
|
|
20234
20253
|
adds: "Progress is saved with JuicyJuicy's window.juicy snippet: signed-in players get it on any browser, everyone else keeps it in this one.",
|
|
20235
20254
|
why: "Players come back on another computer or phone, or after clearing their browser, and pick up where they left off.",
|
|
20236
20255
|
detection: { kind: "marker", marker: GAME_MESSAGES.save },
|
|
@@ -20238,11 +20257,12 @@ var GAME_FEATURES = [
|
|
|
20238
20257
|
recipe: "reference/cloud-saves.md",
|
|
20239
20258
|
task: "add JuicyJuicy cloud saves",
|
|
20240
20259
|
docs: "/docs/publish#saves",
|
|
20241
|
-
missingHint: "paste the window.juicy snippet (https://juicyjuicy.games/docs/publish#saves) and save with juicy.save(), or take it out of features"
|
|
20260
|
+
missingHint: "paste the window.juicy snippet (https://juicyjuicy.games/docs/publish/cli#saves) and save with juicy.save(), or take it out of features"
|
|
20242
20261
|
},
|
|
20243
20262
|
{
|
|
20244
20263
|
id: "multi-language",
|
|
20245
20264
|
name: "Multi-language",
|
|
20265
|
+
summary: "Players switch between English, French, Italian, German, Spanish and Polish.",
|
|
20246
20266
|
adds: "The game plays in English by default, with a switch to French, Italian, German, Spanish and Polish.",
|
|
20247
20267
|
why: "Players who don't read English, or prefer their own language, can enjoy the game, and it shows up in the Language filter for each.",
|
|
20248
20268
|
detection: { kind: "languages" },
|
|
@@ -20345,7 +20365,7 @@ function featureFindings(input2) {
|
|
|
20345
20365
|
findings.push({
|
|
20346
20366
|
rule: "unknown-feature",
|
|
20347
20367
|
severity: "warning",
|
|
20348
|
-
message: `juicy.json lists "${id}" in features, which this version of JuicyJuicy doesn't know; update the CLI (npx juicyjuicy@latest) or take it out`
|
|
20368
|
+
message: `juicy.json lists "${id}" in features, which this version of JuicyJuicy doesn't know; update the CLI and the skill (npx -y juicyjuicy@latest setup --yes) or take it out`
|
|
20349
20369
|
});
|
|
20350
20370
|
continue;
|
|
20351
20371
|
}
|
|
@@ -20362,6 +20382,7 @@ function featureFindings(input2) {
|
|
|
20362
20382
|
}
|
|
20363
20383
|
|
|
20364
20384
|
// ../shared/src/requirements.ts
|
|
20385
|
+
var CHECK_GAMES_COMMAND = cliCommand("check-games");
|
|
20365
20386
|
var GAME_REQUIREMENTS = [
|
|
20366
20387
|
{
|
|
20367
20388
|
id: "features-declared",
|
|
@@ -20453,16 +20474,6 @@ function requirementTask(requirement) {
|
|
|
20453
20474
|
}
|
|
20454
20475
|
return `make the game meet "${requirement.title}"`;
|
|
20455
20476
|
}
|
|
20456
|
-
function compareVersions(a2, b) {
|
|
20457
|
-
const parts = (version2) => version2.split("-")[0]?.split(".").map((part) => Number.parseInt(part, 10) || 0) ?? [];
|
|
20458
|
-
const left = parts(a2);
|
|
20459
|
-
const right = parts(b);
|
|
20460
|
-
for (let i2 = 0; i2 < Math.max(left.length, right.length); i2++) {
|
|
20461
|
-
const difference = (left[i2] ?? 0) - (right[i2] ?? 0);
|
|
20462
|
-
if (difference !== 0) return Math.sign(difference);
|
|
20463
|
-
}
|
|
20464
|
-
return 0;
|
|
20465
|
-
}
|
|
20466
20477
|
|
|
20467
20478
|
// ../shared/src/tokens.ts
|
|
20468
20479
|
var TOKEN_PREFIX = "jj_pat_";
|
|
@@ -24655,7 +24666,7 @@ var program = new Command();
|
|
|
24655
24666
|
// package.json
|
|
24656
24667
|
var package_default = {
|
|
24657
24668
|
name: "juicyjuicy",
|
|
24658
|
-
version: "0.
|
|
24669
|
+
version: "0.7.0",
|
|
24659
24670
|
description: "Publish AI-made browser games to juicyjuicy.games",
|
|
24660
24671
|
type: "module",
|
|
24661
24672
|
license: "MIT",
|
|
@@ -26343,7 +26354,7 @@ async function checkGames(out) {
|
|
|
26343
26354
|
}
|
|
26344
26355
|
bar?.stop(`Checked ${result.games.length} ${result.games.length === 1 ? "game" : "games"}`);
|
|
26345
26356
|
const failing = result.games.filter((game) => game.requirements.some((r2) => !r2.passed));
|
|
26346
|
-
const next = failing.length > 0 ? `For each game in "toFix", follow the juicyjuicy-publish skill's "Bring all my games up to date": pull it (
|
|
26357
|
+
const next = failing.length > 0 ? `For each game in "toFix", follow the juicyjuicy-publish skill's "Bring all my games up to date": pull it (${cliCommand("pull <slug>")}) unless its project is here, apply each prompt, and publish an update.${result.notReached.length > 0 ? " Then run check-games again for the games not reached." : ""}` : result.notReached.length > 0 ? "Some games weren't reached: run check-games again." : "Every game is up to date with JuicyJuicy's requirements.";
|
|
26347
26358
|
out.result(
|
|
26348
26359
|
{
|
|
26349
26360
|
games: result.games,
|
|
@@ -26424,7 +26435,7 @@ async function loadManifest(dir) {
|
|
|
26424
26435
|
const raw = await readRawManifest(dir);
|
|
26425
26436
|
if (!raw) {
|
|
26426
26437
|
throw new CliError("INVALID_MANIFEST", `There's no ${MANIFEST_FILE} in ${dir}.`, {
|
|
26427
|
-
hint:
|
|
26438
|
+
hint: `Run \`npx juicyjuicy init\` to create one. AI agents: \`${cliCommand("setup")}\` installs the JuicyJuicy skill, which has the whole publishing procedure.`
|
|
26428
26439
|
});
|
|
26429
26440
|
}
|
|
26430
26441
|
const parsed = manifestSchema.safeParse(raw);
|
package/dist/skill/SKILL.md
CHANGED
|
@@ -9,17 +9,19 @@ JuicyJuicy hosts **static browser games** (HTML/JS/CSS/assets, WebAssembly) and
|
|
|
9
9
|
|
|
10
10
|
Run every CLI command with `--json`. Each output line is a JSON object; the **last** line is the result, either `{"ok": true, …}` or `{"ok": false, "error": {"code", "message", "details"?, "hint"?}}`. The exit code is `0` (ok), `1` (fix the game or `juicy.json`), `2` (log in) or `3` (network or server problem, so retry).
|
|
11
11
|
|
|
12
|
+
Run the CLI exactly as written here, `npx -y juicyjuicy@0.7.0 …`: this skill is made for that release. If JuicyJuicy answers that the CLI is out of date, run the command its message gives. It updates the CLI and this skill together; read this skill again afterwards and use the release it names from then on.
|
|
13
|
+
|
|
12
14
|
## Procedure
|
|
13
15
|
|
|
14
16
|
### 1. Make sure the CLI is logged in
|
|
15
17
|
|
|
16
18
|
```bash
|
|
17
|
-
npx -y juicyjuicy@0 whoami --json
|
|
19
|
+
npx -y juicyjuicy@0.7.0 whoami --json
|
|
18
20
|
```
|
|
19
21
|
|
|
20
22
|
If it exits with `2`, log in. `login` opens the user's browser and **waits up to 10 minutes** for them to approve:
|
|
21
23
|
|
|
22
|
-
- Run `npx -y juicyjuicy@0 login --json` in the background if your shell can, and read its first output line (`{"event": "device_code", "userCode", "verificationUrl"}`) right away, and show the user the code and link without waiting for them to ask: the page shows the same code, and that's how they know the login is theirs.
|
|
24
|
+
- Run `npx -y juicyjuicy@0.7.0 login --json` in the background if your shell can, and read its first output line (`{"event": "device_code", "userCode", "verificationUrl"}`) right away, and show the user the code and link without waiting for them to ask: the page shows the same code, and that's how they know the login is theirs.
|
|
23
25
|
- Then tell the user, with the real code and link: *"A JuicyJuicy page opened in your browser. Check it shows the code **WXTZ-BCDF** and click **Approve**. If no page opened, go to <verificationUrl>."*
|
|
24
26
|
- If your shell can't run commands in the background, say that first (without a code: it doesn't exist yet), then run it in the foreground with a timeout of at least 10 minutes. The code is also printed as `Your code: …`.
|
|
25
27
|
- The user needs a JuicyJuicy account (it's invite-only for now). If the page says they can't sign in, they need an invite link from a friend who's a member.
|
|
@@ -43,7 +45,7 @@ Files and folders starting with `.` (`.env`, `.git/`, …) and `node_modules/` a
|
|
|
43
45
|
`juicy.json` sits in the project folder and describes the game. Create or update it with `init`, filling in what you know from the game you built:
|
|
44
46
|
|
|
45
47
|
```bash
|
|
46
|
-
npx -y juicyjuicy@0 init --yes --json \
|
|
48
|
+
npx -y juicyjuicy@0.7.0 init --yes --json \
|
|
47
49
|
--title "Snake Deluxe" \
|
|
48
50
|
--description "Eat the apples, don't bite your tail. Arrow keys or swipe." \
|
|
49
51
|
--made-with "<your model name>, <the tool you run in>" \
|
|
@@ -82,7 +84,7 @@ To replace it, the user saves a screenshot as `thumbnail.png` in the project fol
|
|
|
82
84
|
|
|
83
85
|
Do this **every time**, also for updates. It protects the user and their players; JuicyJuicy's server runs its own checks as well, so this is help, not a formality to get past.
|
|
84
86
|
|
|
85
|
-
1. **Check.** Run `npx -y juicyjuicy@0 check --json`. Errors (a failed result) must be fixed: explain each one (`details` has a `rule` and a `path`), and offer to fix it. If the user says no, **stop and don't publish**: the server would refuse it anyway. Warnings in the result (`findings`) go into step 2.
|
|
87
|
+
1. **Check.** Run `npx -y juicyjuicy@0.7.0 check --json`. Errors (a failed result) must be fixed: explain each one (`details` has a `rule` and a `path`), and offer to fix it. If the user says no, **stop and don't publish**: the server would refuse it anyway. Warnings in the result (`findings`) go into step 2.
|
|
86
88
|
Every file in the result's `files` will be public. If `unusualFiles` isn't empty (names that look like keys or private data, project files like `package.json`, notes and other files a web game doesn't load), **show the user that list and ask whether those files should be public** before publishing; offer to move them out of the build folder or set `buildDir` to a folder with just the game.
|
|
87
89
|
2. **Security review.** Follow [reference/review.md](reference/review.md): keys and tokens, `innerHTML`/`eval` on network or multiplayer data, `http://` loads, trackers, login or payment forms, anything that leaves the page. Same rule: for what it marks as must-fix, fix it or don't publish.
|
|
88
90
|
3. **Standards.** Check the game against these and tell the user, in a sentence or two, what falls short; offer to fix it. A "no" still publishes: not every game can have touch controls.
|
|
@@ -111,7 +113,7 @@ Keep it short when there's nothing to say: "Checked: no problems found" is enoug
|
|
|
111
113
|
### 6. Publish
|
|
112
114
|
|
|
113
115
|
```bash
|
|
114
|
-
npx -y juicyjuicy@0 publish --json --message "<what changed, in a few words>"
|
|
116
|
+
npx -y juicyjuicy@0.7.0 publish --json --message "<what changed, in a few words>"
|
|
115
117
|
```
|
|
116
118
|
|
|
117
119
|
This makes the new version live: when the user says "publish", that's what they want. Don't add `--draft` (see "Other commands") unless they asked in words for it not to go live yet. Not for a first publish, a big game or one you're unsure of either: the user would have to find the dashboard and make it live themselves.
|
|
@@ -136,7 +138,7 @@ The game's page under My games on JuicyJuicy has an **Upgrades** panel; its Add
|
|
|
136
138
|
|
|
137
139
|
Other features on the panel (global highscores, multiplayer, touch controls, gamepad, mouse lock, auto-pause) are "Coming soon" and have no recipe yet: if asked for one, say so, and build it your own way only if the user wants.
|
|
138
140
|
|
|
139
|
-
1. **Find the project.** Log in first (step 1). The project is the folder whose `juicy.json` has the game's `slug`: the current folder, or one the user points you to. **If it isn't on this computer** (or you're in a chat app or sandbox), download the live version: `npx -y juicyjuicy@0 pull <slug> --json` writes it into a new folder named after the slug (`dir` in the result) with its `juicy.json`, and you work there. Read the result's `next`: the download is the built game, so for a bundled one (minified code), ask whether the user has the source somewhere, or use `sourceUrl`, before changing the bundle itself. `pull` only works for the user's own games (`NOT_FOUND` otherwise).
|
|
141
|
+
1. **Find the project.** Log in first (step 1). The project is the folder whose `juicy.json` has the game's `slug`: the current folder, or one the user points you to. **If it isn't on this computer** (or you're in a chat app or sandbox), download the live version: `npx -y juicyjuicy@0.7.0 pull <slug> --json` writes it into a new folder named after the slug (`dir` in the result) with its `juicy.json`, and you work there. Read the result's `next`: the download is the built game, so for a bundled one (minified code), ask whether the user has the source somewhere, or use `sourceUrl`, before changing the bundle itself. `pull` only works for the user's own games (`NOT_FOUND` otherwise).
|
|
140
142
|
2. **Read the recipe** for the upgrade and make the change. Keep everything else about the game as it is.
|
|
141
143
|
3. **Build and try it** (step 2), then **declare it** in `juicy.json` as the table says, adding to what's already listed.
|
|
142
144
|
4. **Review and publish** as steps 5–7 say, with `--message "Add <upgrade>"`. In step 5's `check` result, `features.detected` lists what JuicyJuicy found in the files; a `feature-missing` warning means a declared upgrade isn't there yet: fix it before publishing.
|
|
@@ -144,14 +146,14 @@ Other features on the panel (global highscores, multiplayer, touch controls, gam
|
|
|
144
146
|
|
|
145
147
|
## Bring all my games up to date
|
|
146
148
|
|
|
147
|
-
When the user asks to bring their JuicyJuicy games up to date or fix a **Needs update** badge, when `check` warns `requirement-missing`, or after updating the CLI: follow [reference/update-all-games.md](reference/update-all-games.md). It starts with `npx -y juicyjuicy@0 check-games --json`, which checks every game of the user's at once and settles what a script can; the rest are code changes, one game at a time.
|
|
149
|
+
When the user asks to bring their JuicyJuicy games up to date or fix a **Needs update** badge, when `check` warns `requirement-missing`, or after updating the CLI: follow [reference/update-all-games.md](reference/update-all-games.md). It starts with `npx -y juicyjuicy@0.7.0 check-games --json`, which checks every game of the user's at once and settles what a script can; the rest are code changes, one game at a time.
|
|
148
150
|
|
|
149
151
|
## Remix a game
|
|
150
152
|
|
|
151
153
|
A game marked remixable on JuicyJuicy can be downloaded, changed and published as a new game that links back to it. Log in first (step 1), then:
|
|
152
154
|
|
|
153
155
|
```bash
|
|
154
|
-
npx -y juicyjuicy@0 remix <slug> --json
|
|
156
|
+
npx -y juicyjuicy@0.7.0 remix <slug> --json
|
|
155
157
|
```
|
|
156
158
|
|
|
157
159
|
- The first line is `{"event": "license", "name", "text"}`: the remix license. Tell the user in a sentence what it says. In short: the remix may be published **on JuicyJuicy only**, never anywhere else, and the files aren't to be passed on. The full text is:
|
|
@@ -186,9 +188,9 @@ Everything else is in [reference/troubleshooting.md](reference/troubleshooting.m
|
|
|
186
188
|
|
|
187
189
|
## Other commands
|
|
188
190
|
|
|
189
|
-
- `npx -y juicyjuicy@0 list --json`: the user's games; `list <slug>` shows one game's versions. `--all` lists every game on JuicyJuicy instead (60 a page, `--page 2` and on; `nextPage` in the result), `--owner <username>` another creator's. Narrow and order any list with `--search <title text>`, `--tag`, `--engine`, `--remixes`, `--sort newest|upvoted|downvoted|played` and `--period 24h|week|month|all`, e.g. to find a game to remix.
|
|
190
|
-
- `npx -y juicyjuicy@0 publish --draft --json`: uploads a new version without making it live (players keep the current one). Only when the user asks for that in words (e.g. "upload it but don't put it live yet"), never on your own judgment. The result has `draft: true`; when they say so, make it live with `rollback <version>`, or they can on the dashboard.
|
|
191
|
-
- `npx -y juicyjuicy@0 rollback <version> --slug <slug> --json`: makes an earlier version or a draft live, e.g. when the user says the last update broke the game. Run `list <slug>` first to pick the version with the user; one waiting for an admin's review can't be made live (`FORBIDDEN`).
|
|
192
|
-
- `npx -y juicyjuicy@0 pull <slug> --json`: downloads the live version of one of the user's own games into a new folder with its `juicy.json`, to change it when the project isn't on this computer (see "Add a JuicyJuicy upgrade").
|
|
193
|
-
- `npx -y juicyjuicy@0 check-games --json`: checks all the user's games against JuicyJuicy's features and required updates, declares the features it finds where a game never declared them, and lists what still needs a change (see "Bring all my games up to date").
|
|
194
|
-
- `npx -y juicyjuicy@0 open <slug>`: opens the game page in the browser.
|
|
191
|
+
- `npx -y juicyjuicy@0.7.0 list --json`: the user's games; `list <slug>` shows one game's versions. `--all` lists every game on JuicyJuicy instead (60 a page, `--page 2` and on; `nextPage` in the result), `--owner <username>` another creator's. Narrow and order any list with `--search <title text>`, `--tag`, `--engine`, `--remixes`, `--sort newest|upvoted|downvoted|played` and `--period 24h|week|month|all`, e.g. to find a game to remix.
|
|
192
|
+
- `npx -y juicyjuicy@0.7.0 publish --draft --json`: uploads a new version without making it live (players keep the current one). Only when the user asks for that in words (e.g. "upload it but don't put it live yet"), never on your own judgment. The result has `draft: true`; when they say so, make it live with `rollback <version>`, or they can on the dashboard.
|
|
193
|
+
- `npx -y juicyjuicy@0.7.0 rollback <version> --slug <slug> --json`: makes an earlier version or a draft live, e.g. when the user says the last update broke the game. Run `list <slug>` first to pick the version with the user; one waiting for an admin's review can't be made live (`FORBIDDEN`).
|
|
194
|
+
- `npx -y juicyjuicy@0.7.0 pull <slug> --json`: downloads the live version of one of the user's own games into a new folder with its `juicy.json`, to change it when the project isn't on this computer (see "Add a JuicyJuicy upgrade").
|
|
195
|
+
- `npx -y juicyjuicy@0.7.0 check-games --json`: checks all the user's games against JuicyJuicy's features and required updates, declares the features it finds where a game never declared them, and lists what still needs a change (see "Bring all my games up to date").
|
|
196
|
+
- `npx -y juicyjuicy@0.7.0 open <slug>`: opens the game page in the browser.
|
|
@@ -16,4 +16,4 @@ JuicyJuicy offers English, French, Italian, German, Spanish and Polish (`en`, `f
|
|
|
16
16
|
Run the game, switch to each language and go through the menus and the first minute of play: no missing keys (an untranslated key shows up as the key's name), no clipped text, and the choice is still there after a reload.
|
|
17
17
|
|
|
18
18
|
## Declare it
|
|
19
|
-
Set `languages` in `juicy.json` to every language the game now has, English first, e.g. `"languages": ["en", "fr", "pl"]` (or `npx -y juicyjuicy@0 init --yes --json --languages en,fr,pl`). Don't add it to `features`: JuicyJuicy reads `languages`, and shows the game in each language's filter.
|
|
19
|
+
Set `languages` in `juicy.json` to every language the game now has, English first, e.g. `"languages": ["en", "fr", "pl"]` (or `npx -y juicyjuicy@0.7.0 init --yes --json --languages en,fr,pl`). Don't add it to `features`: JuicyJuicy reads `languages`, and shows the game in each language's filter.
|
|
@@ -6,7 +6,7 @@ With `--json`, a failed command's last line is `{"ok": false, "error": {"code",
|
|
|
6
6
|
|
|
7
7
|
| Code | Meaning | Fix |
|
|
8
8
|
|---|---|---|
|
|
9
|
-
| `UNAUTHORIZED` | No saved login, or the token was revoked. | `npx -y juicyjuicy@0 login --json` (the user approves in the browser). In CI, set `JUICY_TOKEN`. |
|
|
9
|
+
| `UNAUTHORIZED` | No saved login, or the token was revoked. | `npx -y juicyjuicy@0.7.0 login --json` (the user approves in the browser). In CI, set `JUICY_TOKEN`. |
|
|
10
10
|
| `EXPIRED_TOKEN` | The login code expired (10 minutes) or was used. | Run `login` again. |
|
|
11
11
|
| `ACCESS_DENIED` | The user clicked Deny. | Ask them, then run `login` again. |
|
|
12
12
|
|
|
@@ -19,7 +19,7 @@ With `--json`, a failed command's last line is `{"ok": false, "error": {"code",
|
|
|
19
19
|
| `INVALID_PATH` | A file name is unsafe (backslash, control character, too long, …). | Rename the file (POSIX names, under 256 characters). |
|
|
20
20
|
| `TOO_LARGE` | A file is over 100 MB, the whole build over 150 MB, or the thumbnail over 2 MB or 4096 pixels wide or high. Or the user's games together take up more than their 2 GB of storage (the message says "your games already take up"). | Compress or remove assets; resize the thumbnail. For storage: the user deletes a game they don't need on the site; only the newest 5 versions of each game are kept, and old ones are cleaned up daily. |
|
|
21
21
|
| `TOO_MANY_FILES` | More than 3,000 files. | Bundle or pack assets (sprite sheets, atlases). |
|
|
22
|
-
| `VALIDATION_FAILED` | Something else is malformed, e.g. a thumbnail that isn't png/jpg/webp or a file that's missing. | Follow the message. |
|
|
22
|
+
| `VALIDATION_FAILED` | Something else is malformed, e.g. a thumbnail that isn't png/jpg/webp or a file that's missing. Or the message says the CLI is out of date: JuicyJuicy needs a newer release than the one run. | Follow the message. For an out-of-date CLI, run the `setup` command it gives (it updates the CLI and the skill), read the skill again and use the release it names. |
|
|
23
23
|
| `SLUG_TAKEN` | Another creator owns this slug. | Choose a new slug: `init --slug <new-slug>`. |
|
|
24
24
|
| `GAME_LIMIT_REACHED` | The user has 25 games already. | They delete one on the site, or update an existing game instead. |
|
|
25
25
|
| `FORBIDDEN` | The game was removed by an admin, or isn't theirs. | Publish under a new slug; ask an admin if unsure. |
|
|
@@ -5,7 +5,7 @@ For "bring my JuicyJuicy games up to date", "fix the required updates", a **Need
|
|
|
5
5
|
1. **Check every game at once.** Log in first (SKILL.md step 1), then run:
|
|
6
6
|
|
|
7
7
|
```bash
|
|
8
|
-
npx -y juicyjuicy@0 check-games --json
|
|
8
|
+
npx -y juicyjuicy@0.7.0 check-games --json
|
|
9
9
|
```
|
|
10
10
|
|
|
11
11
|
JuicyJuicy checks the live version of each of the user's games on its side. It records which features each one has and, for a game whose `juicy.json` never listed its `features`, declares what it finds in the files (like cloud saves). Nothing is uploaded and no new version is made. The result has one entry per game in `games` (`features` with `on`/`off`/`unknown`, `requirements` with `passed`), `toFix` (the games that still need a code change, each with its `prompts`), `notReached` and `next`.
|
|
@@ -13,7 +13,7 @@ For "bring my JuicyJuicy games up to date", "fix the required updates", a **Need
|
|
|
13
13
|
2. **If `notReached` isn't empty**, run `check-games` again: it had no time for those games.
|
|
14
14
|
|
|
15
15
|
3. **For each game in `toFix`**, one at a time:
|
|
16
|
-
- Find its project, or download the live version with `npx -y juicyjuicy@0 pull <slug> --json` (SKILL.md, "Add a JuicyJuicy upgrade", step 1).
|
|
16
|
+
- Find its project, or download the live version with `npx -y juicyjuicy@0.7.0 pull <slug> --json` (SKILL.md, "Add a JuicyJuicy upgrade", step 1).
|
|
17
17
|
- Do what each prompt says, with the recipe it names when it names one.
|
|
18
18
|
- Make sure `juicy.json` has `features` (`[]` if the game has none of the upgrades).
|
|
19
19
|
- Check and publish an update as SKILL.md steps 5–7 say, with `--message "Required update: <what>"`.
|