@devtune/agentpicks 0.4.7 → 0.4.8
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 +5 -5
- package/dist/cli.js +27 -19
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -163,13 +163,13 @@ agentpicks init --category authentication --tool clerk --competitors authjs,okta
|
|
|
163
163
|
- **Requests**, for a job of your own: the add request a run asks, the recommend request `push` saves with it, and a hosted request or none.
|
|
164
164
|
- **Your tool**: a catalogue tool named by your `package.json` name or scope, or your git remote's repository or owner, such as `sentry` from `getsentry/sentry-docs`.
|
|
165
165
|
- **Competitors**: for a category, its tools; for your own job, typed as npm packages.
|
|
166
|
-
- **Where to test**: `repo: .` in a git repository, else the stacks your `package.json` and lockfiles name (`next`, `@tanstack/react-start`, `@sveltejs/kit` and `express`, a pnpm monorepo's apps included, plus FastAPI and Rails).
|
|
166
|
+
- **Where to test**: this repository (`repo`, written `repo: .`), every stack the job runs in (`all`), or stacks by number or range. The default is `repo` in a git repository, else the stacks your `package.json` and lockfiles name (`next`, `@tanstack/react-start`, `@sveltejs/kit` and `express`, a pnpm monorepo's apps included, plus FastAPI and Rails).
|
|
167
167
|
- **Agents**: those installed here that `run` could start now, with their sign-in or key.
|
|
168
168
|
- **Runs** and the setup's **name**.
|
|
169
169
|
|
|
170
170
|
For a custom setup, run `agentpicks push <setup>` before running it with uploads.
|
|
171
171
|
|
|
172
|
-
Each question also has a flag, which takes keys, never list numbers: `--category <category>` or `--job <line>`, `--tool <tool>` or `none`, `--competitors <tool>,<tool>` or `all`, `--repo .` or `--stack <stack
|
|
172
|
+
Each question also has a flag, which takes keys, never list numbers: `--category <category>` or `--job <line>`, `--tool <tool>` or `none`, `--competitors <tool>,<tool>` or `all`, `--repo .` or `--stack <stack>` or `all`, `--agent <agent>` or `any`, `--runs <n>` and `--name <name>`. `--stack` and `--agent` repeat, or take a comma list. `init` asks only what the flags leave, and refuses a flag value that doesn't read, naming the flag. A job line's requests and tools have no flags: answer them on a terminal or, signed in, take DevTune's drafts with `--yes`. Without a sign-in, type them on a terminal, or have your coding agent write the file against `agentpicks schema` and check it with `agentpicks validate`.
|
|
173
173
|
|
|
174
174
|
`agentpicks catalogue` lists the category, tool and stack keys the flags take: every category and the stacks a job line can run in. `agentpicks catalogue <category>` lists the category's tool keys and the stacks it runs in. `--json` prints either as one JSON object.
|
|
175
175
|
|
|
@@ -288,7 +288,7 @@ jobs:
|
|
|
288
288
|
steps:
|
|
289
289
|
- uses: actions/checkout@v5
|
|
290
290
|
- run: npm install -g @anthropic-ai/claude-code@2.1.323
|
|
291
|
-
- uses: devtunehq/agentpicks@v0.4.
|
|
291
|
+
- uses: devtunehq/agentpicks@v0.4.8
|
|
292
292
|
with:
|
|
293
293
|
setup: agentpicks/error-tracking.yaml
|
|
294
294
|
agent: claude-code
|
|
@@ -302,7 +302,7 @@ jobs:
|
|
|
302
302
|
|
|
303
303
|
Use a Linux runner: `ubuntu-latest` has Docker and Node.js 20 or later. Without Docker, `run` refuses; without Node.js 20 or later, the action does. The action uses the runner's Node.js and doesn't change it for later steps.
|
|
304
304
|
|
|
305
|
-
Pin a release tag, such as `v0.4.
|
|
305
|
+
Pin a release tag, such as `v0.4.8`. The action runs the `@devtune/agentpicks` version in the `package.json` of its ref, so a tag runs the same CLI every time. A branch moves to each new version when the mirror syncs, and fails while that version isn't on npm.
|
|
306
306
|
|
|
307
307
|
| Input | Passed as |
|
|
308
308
|
|---|---|
|
|
@@ -343,7 +343,7 @@ Install Docker, Node.js 20 or later and the agent, set `DEVTUNE_API_KEY`, `DEVTU
|
|
|
343
343
|
|
|
344
344
|
```sh
|
|
345
345
|
npm install -g @anthropic-ai/claude-code@2.1.323
|
|
346
|
-
npx --yes @devtune/agentpicks@0.4.
|
|
346
|
+
npx --yes @devtune/agentpicks@0.4.8 run error-tracking --agent claude-code
|
|
347
347
|
```
|
|
348
348
|
|
|
349
349
|
## The bundle
|
package/dist/cli.js
CHANGED
|
@@ -7375,7 +7375,7 @@ var import_promises5 = require("node:readline/promises");
|
|
|
7375
7375
|
// package.json
|
|
7376
7376
|
var package_default = {
|
|
7377
7377
|
name: "@devtune/agentpicks",
|
|
7378
|
-
version: "0.4.
|
|
7378
|
+
version: "0.4.8",
|
|
7379
7379
|
description: "The open Agent Picks runner: the agentpicks CLI, which tests the coding agents installed on your machine in fresh Docker containers, and the sandbox code DevTune runs its managed tests on",
|
|
7380
7380
|
license: "Apache-2.0",
|
|
7381
7381
|
engines: {
|
|
@@ -81582,15 +81582,17 @@ async function ensureSandboxImage({
|
|
|
81582
81582
|
build = dockerBuild
|
|
81583
81583
|
}) {
|
|
81584
81584
|
const tag = sandboxImageTag(version2);
|
|
81585
|
-
const
|
|
81586
|
-
|
|
81587
|
-
|
|
81588
|
-
|
|
81589
|
-
|
|
81590
|
-
|
|
81591
|
-
|
|
81592
|
-
|
|
81593
|
-
return
|
|
81585
|
+
const present = async () => {
|
|
81586
|
+
const inspect = await run([
|
|
81587
|
+
"image",
|
|
81588
|
+
"inspect",
|
|
81589
|
+
"--format",
|
|
81590
|
+
"{{.Os}}/{{.Architecture}}",
|
|
81591
|
+
tag
|
|
81592
|
+
]);
|
|
81593
|
+
return inspect.exitCode === 0 && inspect.stdout.trim() === platform;
|
|
81594
|
+
};
|
|
81595
|
+
if (await present()) return { tag, built: false, removed: [] };
|
|
81594
81596
|
const code = await build([
|
|
81595
81597
|
"build",
|
|
81596
81598
|
"--platform",
|
|
@@ -81607,6 +81609,10 @@ async function ensureSandboxImage({
|
|
|
81607
81609
|
throw new Error(
|
|
81608
81610
|
`Building the sandbox image ${tag} failed (docker build exit ${code}); Docker's output is above.`
|
|
81609
81611
|
);
|
|
81612
|
+
if (!await present())
|
|
81613
|
+
throw new Error(
|
|
81614
|
+
`docker build finished, but this machine's Docker has no ${tag} for ${platform}, so no run can start. The build went to a builder that keeps its images elsewhere, such as Depot after depot configure-docker. Run depot configure-docker --uninstall, or docker buildx use default, then run agentpicks again.`
|
|
81615
|
+
);
|
|
81610
81616
|
return { tag, built: true, removed: await removeOlderImages(tag, run) };
|
|
81611
81617
|
}
|
|
81612
81618
|
async function removeOlderImages(keep, run = docker) {
|
|
@@ -81649,7 +81655,6 @@ async function labelledImages(run) {
|
|
|
81649
81655
|
const r = await run([
|
|
81650
81656
|
"image",
|
|
81651
81657
|
"ls",
|
|
81652
|
-
"--all",
|
|
81653
81658
|
"--no-trunc",
|
|
81654
81659
|
"--filter",
|
|
81655
81660
|
`label=${DOCKER_SANDBOX_LABEL}`,
|
|
@@ -82358,11 +82363,11 @@ function checkFlags(wizard) {
|
|
|
82358
82363
|
const given = stack.join(",");
|
|
82359
82364
|
refuseListNumbers("--stack", given, "agentpicks catalogue");
|
|
82360
82365
|
const unknown2 = entries(given).find(
|
|
82361
|
-
(slug2) => !findEnvironment(slug2) || isRetiredEnvironment(slug2)
|
|
82366
|
+
(slug2) => slug2 !== "all" && (!findEnvironment(slug2) || isRetiredEnvironment(slug2))
|
|
82362
82367
|
);
|
|
82363
82368
|
if (unknown2 !== void 0)
|
|
82364
82369
|
throw new UsageError(
|
|
82365
|
-
`--stack: ${unknown2} isn't a stack. Give stack slugs. List the keys with: agentpicks catalogue`
|
|
82370
|
+
`--stack: ${unknown2} isn't a stack. Give stack slugs, or all. List the keys with: agentpicks catalogue`
|
|
82366
82371
|
);
|
|
82367
82372
|
}
|
|
82368
82373
|
read(agentsQuestion(wizard));
|
|
@@ -82505,14 +82510,16 @@ function testsQuestion(wizard, from) {
|
|
|
82505
82510
|
const detected = stacks.filter((stack2) => choices.includes(stack2));
|
|
82506
82511
|
const { repo, stack } = wizard.flags;
|
|
82507
82512
|
return {
|
|
82508
|
-
label: "
|
|
82509
|
-
fallback: git ? "
|
|
82513
|
+
label: "Where to test: this repository (repo), all stacks (all), or stack numbers or ranges separated by commas (1, 3-4)",
|
|
82514
|
+
fallback: git ? "repo" : detected.join(", ") || null,
|
|
82510
82515
|
missing: `found nothing to test in: ${root} isn't a git repository, and its package.json and lockfiles name no framework of a stack (${choices.join(", ")}). Run it in a git repository, or on a terminal to choose stacks.`,
|
|
82511
82516
|
flag: repo !== void 0 ? "--repo" : stack.length > 0 || !git ? "--stack" : "--repo . or --stack",
|
|
82512
82517
|
given: repo ?? (stack.length > 0 ? stack.join(",") : void 0),
|
|
82513
82518
|
keys: repo === void 0 ? `agentpicks catalogue${from ? ` ${from}` : ""}` : void 0,
|
|
82514
82519
|
read: (answer, flag) => {
|
|
82515
|
-
if (answer === "."
|
|
82520
|
+
if (answer === "." || !flag && answer === "repo")
|
|
82521
|
+
return { value: { repo: "." } };
|
|
82522
|
+
if (answer === "all") return { value: { stacks: choices } };
|
|
82516
82523
|
const given = withRanges(answer, choices.length);
|
|
82517
82524
|
const chosen = [
|
|
82518
82525
|
...new Set(given.map((entry) => pickKey(entry, choices)))
|
|
@@ -82520,7 +82527,7 @@ function testsQuestion(wizard, from) {
|
|
|
82520
82527
|
const unknown2 = given.find((entry) => !pickKey(entry, choices));
|
|
82521
82528
|
if (given.length === 0 || unknown2)
|
|
82522
82529
|
return {
|
|
82523
|
-
problem: `${unknown2 ?? "Nothing"} isn't a stack ${from ? `for ${from}` : "for your own job"}. Give ${flag ? "stack slugs" :
|
|
82530
|
+
problem: `${unknown2 ?? "Nothing"} isn't a stack ${from ? `for ${from}` : "for your own job"}. Give ${flag ? "stack slugs, or all" : `repo, all, or numbers from 1 to ${choices.length}`}.`
|
|
82524
82531
|
};
|
|
82525
82532
|
return { value: { stacks: chosen.filter((stack2) => stack2 !== null) } };
|
|
82526
82533
|
}
|
|
@@ -85740,7 +85747,7 @@ var RUNNER = {
|
|
|
85740
85747
|
};
|
|
85741
85748
|
var USAGE = `Usage:
|
|
85742
85749
|
agentpicks init [--yes] [--force] [--category <category> | --job <line>] [--tool <tool>|none]
|
|
85743
|
-
[--competitors <tool>,...|all] [--repo . | --stack <stack
|
|
85750
|
+
[--competitors <tool>,...|all] [--repo . | --stack <stack>...|all]
|
|
85744
85751
|
[--agent <agent>...|any] [--runs <n>] [--name <name>]
|
|
85745
85752
|
agentpicks catalogue [<category>] [--json]
|
|
85746
85753
|
agentpicks run [<setup>] [--stack <stack> | --repo <path> [--ref <commit>]]
|
|
@@ -85766,7 +85773,8 @@ init Writes a setup file, agentpicks/<name>.yaml, from questions whose defa
|
|
|
85766
85773
|
of the same name. Signed in, DevTune drafts the requests and tools of your own job.
|
|
85767
85774
|
Each flag answers one question: --category or --job, --tool, --competitors,
|
|
85768
85775
|
--repo . or --stack, --agent, --runs and --name. Flags take keys, never list numbers;
|
|
85769
|
-
--stack and --agent repeat or take a comma list
|
|
85776
|
+
--stack and --agent repeat or take a comma list, and --stack all takes every stack
|
|
85777
|
+
the job runs in. A question a flag answers isn't
|
|
85770
85778
|
asked. A flag value that doesn't read stops init before it asks anything, unless the
|
|
85771
85779
|
check needs an earlier answer, such as --competitors against the tool this
|
|
85772
85780
|
repository names, which waits for that question. Off a terminal, a question no flag
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@devtune/agentpicks",
|
|
3
|
-
"version": "0.4.
|
|
3
|
+
"version": "0.4.8",
|
|
4
4
|
"description": "The open Agent Picks runner: the agentpicks CLI, which tests the coding agents installed on your machine in fresh Docker containers, and the sandbox code DevTune runs its managed tests on",
|
|
5
5
|
"license": "Apache-2.0",
|
|
6
6
|
"engines": {
|