@joiner-platform/cli 0.1.11 → 0.1.12
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 +7 -1
- package/bundled-resources/poe-tile-templates/base/scripts/doctor.sh +2 -1
- package/bundled-resources/poe-tile-templates/package.json +1 -1
- package/bundled-resources/poe-tile-templates/tests/doctor-launcher.test.ts +48 -0
- package/cli.ts +8 -0
- package/package.json +2 -2
- package/skills/tile-creator/references/cli.md +1 -1
- package/src/commands/init/sdk-tarball-url.generated.ts +2 -2
- package/src/should-skip-client-setup.ts +2 -1
package/README.md
CHANGED
|
@@ -2,10 +2,16 @@
|
|
|
2
2
|
|
|
3
3
|
The Joiner command line: create, test, and publish Joiner tiles.
|
|
4
4
|
|
|
5
|
-
##
|
|
5
|
+
## Create a tile
|
|
6
6
|
|
|
7
7
|
Joiner runs on [Bun](https://bun.sh) 1.4.2 or later.
|
|
8
8
|
|
|
9
|
+
```bash
|
|
10
|
+
bunx @joiner-platform/cli@latest create my-tile
|
|
11
|
+
```
|
|
12
|
+
|
|
13
|
+
## Install
|
|
14
|
+
|
|
9
15
|
```bash
|
|
10
16
|
npm install -g @joiner-platform/cli
|
|
11
17
|
joiner login
|
|
@@ -21,7 +21,8 @@ if command -v poe-tiles >/dev/null 2>&1; then
|
|
|
21
21
|
fi
|
|
22
22
|
|
|
23
23
|
if command -v bun >/dev/null 2>&1; then
|
|
24
|
-
|
|
24
|
+
# poe-tiles is a bin of @joiner-platform/cli, not an npm package of its own.
|
|
25
|
+
exec bunx --bun --package @joiner-platform/cli poe-tiles doctor --cwd "$PROJECT_ROOT"
|
|
25
26
|
fi
|
|
26
27
|
|
|
27
28
|
echo "Could not run Joiner doctor because Bun is not available."
|
|
@@ -14,7 +14,7 @@
|
|
|
14
14
|
"scripts": {
|
|
15
15
|
"generate-test-apps": "bun scripts/generate.ts && bun install --ignore-scripts --no-save",
|
|
16
16
|
"generate:cleanup": "bun scripts/cleanup.ts",
|
|
17
|
-
"test": "bun test tests/check-source.test.ts tests/playwright-version.test.ts tests/happy-dom-version.test.ts tests/native-gesture-defaults.test.ts tests/visual-check.test.ts tests/install-diagnostics.test.ts tests/render-check-scaffold.test.ts tests/sdk-dependency-key.test.ts",
|
|
17
|
+
"test": "bun test tests/check-source.test.ts tests/playwright-version.test.ts tests/happy-dom-version.test.ts tests/native-gesture-defaults.test.ts tests/visual-check.test.ts tests/install-diagnostics.test.ts tests/render-check-scaffold.test.ts tests/sdk-dependency-key.test.ts tests/doctor-launcher.test.ts",
|
|
18
18
|
"test:generated": "bun test tests/generated-templates.test.ts",
|
|
19
19
|
"test:generated:packaged-sdk": "bun scripts/verify-local-sdk-tarball.ts",
|
|
20
20
|
"test:slow": "bun run generate-test-apps && bun test ./tests/*.test.slow.ts --reporter=junit --reporter-outfile=junit-slow.xml",
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
import { afterEach, expect, test } from "bun:test";
|
|
2
|
+
import {
|
|
3
|
+
chmodSync,
|
|
4
|
+
copyFileSync,
|
|
5
|
+
mkdirSync,
|
|
6
|
+
mkdtempSync,
|
|
7
|
+
realpathSync,
|
|
8
|
+
rmSync,
|
|
9
|
+
writeFileSync,
|
|
10
|
+
} from "node:fs";
|
|
11
|
+
import { tmpdir } from "node:os";
|
|
12
|
+
import { join } from "node:path";
|
|
13
|
+
|
|
14
|
+
const roots: string[] = [];
|
|
15
|
+
afterEach(() => {
|
|
16
|
+
for (const root of roots.splice(0))
|
|
17
|
+
rmSync(root, { recursive: true, force: true });
|
|
18
|
+
});
|
|
19
|
+
|
|
20
|
+
test("doctor runs the npm CLI's poe-tiles bin when only Bun is installed", () => {
|
|
21
|
+
// A tile scaffolded with `bunx @joiner-platform/cli create` has no
|
|
22
|
+
// poe-tiles on PATH and no monorepo checkout around it.
|
|
23
|
+
const root = realpathSync(mkdtempSync(join(tmpdir(), "doctor-launcher-")));
|
|
24
|
+
roots.push(root);
|
|
25
|
+
const scripts = join(root, "tile/scripts");
|
|
26
|
+
mkdirSync(scripts, { recursive: true });
|
|
27
|
+
copyFileSync(
|
|
28
|
+
join(import.meta.dir, "../base/scripts/doctor.sh"),
|
|
29
|
+
join(scripts, "doctor.sh"),
|
|
30
|
+
);
|
|
31
|
+
const bin = join(root, "bin");
|
|
32
|
+
mkdirSync(bin);
|
|
33
|
+
for (const name of ["bun", "bunx"]) {
|
|
34
|
+
writeFileSync(join(bin, name), `#!/bin/sh\necho "${name} $*"\n`);
|
|
35
|
+
chmodSync(join(bin, name), 0o755);
|
|
36
|
+
}
|
|
37
|
+
|
|
38
|
+
const result = Bun.spawnSync(["bash", join(scripts, "doctor.sh")], {
|
|
39
|
+
env: { PATH: `${bin}:/usr/bin:/bin` },
|
|
40
|
+
stdout: "pipe",
|
|
41
|
+
stderr: "pipe",
|
|
42
|
+
});
|
|
43
|
+
|
|
44
|
+
expect(result.stderr.toString()).toBe("");
|
|
45
|
+
expect(result.stdout.toString().trim()).toBe(
|
|
46
|
+
`bunx --bun --package @joiner-platform/cli poe-tiles doctor --cwd ${join(root, "tile")}`,
|
|
47
|
+
);
|
|
48
|
+
});
|
package/cli.ts
CHANGED
|
@@ -22,6 +22,7 @@ import { createAdminCommands } from "./src/commands/admin.js";
|
|
|
22
22
|
import { createAuthCommands } from "./src/commands/auth.js";
|
|
23
23
|
import { createCreatorSourceCapabilityCommand } from "./src/commands/creator-source-capability.js";
|
|
24
24
|
import { createDoctorCommand } from "./src/commands/doctor-command.js";
|
|
25
|
+
import { createInitCommand } from "./src/commands/init/index.js";
|
|
25
26
|
import { createInstallJoinerCommand } from "./src/commands/install-joiner.js";
|
|
26
27
|
import { createLoginCommand } from "./src/commands/login.js";
|
|
27
28
|
import { createModelsCommands } from "./src/commands/models.js";
|
|
@@ -75,6 +76,13 @@ const clientProxy = new Proxy({} as SlopPoeClient, {
|
|
|
75
76
|
program.addCommand(createAuthCommands(clientProxy));
|
|
76
77
|
program.addCommand(createLoginCommand(clientProxy));
|
|
77
78
|
program.addCommand(createTilesCommands(clientProxy));
|
|
79
|
+
// `tiles init` at the top level, so `bunx @joiner-platform/cli@latest create`
|
|
80
|
+
// scaffolds a tile without installing the CLI first.
|
|
81
|
+
program.addCommand(
|
|
82
|
+
createInitCommand()
|
|
83
|
+
.name("create")
|
|
84
|
+
.description("Create a new Joiner tile (same as `tiles init`)"),
|
|
85
|
+
);
|
|
78
86
|
program.addCommand(createRemixCommand(clientProxy));
|
|
79
87
|
program.addCommand(createModelsCommands(clientProxy));
|
|
80
88
|
program.addCommand(createAccountsCommands(clientProxy));
|
package/package.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@joiner-platform/cli",
|
|
3
|
-
"version": "0.1.
|
|
4
|
-
"gitHead": "
|
|
3
|
+
"version": "0.1.12",
|
|
4
|
+
"gitHead": "a81325417bcc0a8a00b86f839c90045dcbf6337c",
|
|
5
5
|
"description": "The Joiner CLI: create, test, and publish Joiner tiles, with agent skills for coding agents.",
|
|
6
6
|
"keywords": [
|
|
7
7
|
"joiner",
|
|
@@ -61,7 +61,7 @@ an older pin, so prefer the live result when upgrading:
|
|
|
61
61
|
|
|
62
62
|
<!-- begin: sdk-tarball-snippet (auto-generated by packages/poe-tiles-sdk/scripts/publish-tar.ts — do not edit by hand) -->
|
|
63
63
|
```json
|
|
64
|
-
"joiner-sdk": "https://misc-dev-uploads.quora-913.workers.dev/
|
|
64
|
+
"joiner-sdk": "https://misc-dev-uploads.quora-913.workers.dev/5ec2f23998b6fd77655102c1e03877f2dfa3339204fc2220c4e157e80a2d61cb"
|
|
65
65
|
```
|
|
66
66
|
<!-- end: sdk-tarball-snippet -->
|
|
67
67
|
|
|
@@ -1,4 +1,4 @@
|
|
|
1
1
|
// Auto-generated by poe-tiles-sdk/scripts/publish-tar.ts — do not edit
|
|
2
|
-
// publishedAt: 2026-11-
|
|
2
|
+
// publishedAt: 2026-11-25T22:17:14.208Z
|
|
3
3
|
export const SDK_TARBALL_URL =
|
|
4
|
-
"https://misc-dev-uploads.quora-913.workers.dev/
|
|
4
|
+
"https://misc-dev-uploads.quora-913.workers.dev/5ec2f23998b6fd77655102c1e03877f2dfa3339204fc2220c4e157e80a2d61cb";
|
|
@@ -8,7 +8,8 @@ export function shouldSkipClientSetup(actionCommand: Command): boolean {
|
|
|
8
8
|
(cmdName === "remix" &&
|
|
9
9
|
actionCommand.getOptionValue("localArchive") !== undefined) ||
|
|
10
10
|
cmdName === "doctor" ||
|
|
11
|
-
(cmdName === "create" &&
|
|
11
|
+
(cmdName === "create" &&
|
|
12
|
+
(parentName === "tiles" || !actionCommand.parent?.parent)) ||
|
|
12
13
|
(cmdName === "inspect" && parentName === "tiles") ||
|
|
13
14
|
cmdName === "init" ||
|
|
14
15
|
parentName === "skills" ||
|