@letterstory/cli 0.176.34 → 0.176.35
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/lib/cli.mjs +1 -1
- package/lib/commands/admin.mjs +4 -2
- package/package.json +1 -1
package/lib/cli.mjs
CHANGED
|
@@ -83,7 +83,7 @@ import {
|
|
|
83
83
|
import { fetchParkedSections, withoutParked } from "./parked.mjs";
|
|
84
84
|
|
|
85
85
|
// Matches cli/package.json; publish-cli.yml rewrites both to the published version.
|
|
86
|
-
export const VERSION = "0.176.
|
|
86
|
+
export const VERSION = "0.176.35";
|
|
87
87
|
|
|
88
88
|
/** The exit code for a gate refusal (CARD_REQUIRED, PAYMENT_FAILED, OUT_OF_TOKENS): 1 is a plain error. */
|
|
89
89
|
export const EXIT_PAYMENT_REQUIRED = 3;
|
package/lib/commands/admin.mjs
CHANGED
|
@@ -5240,6 +5240,7 @@ function recipeFromFlags(flags) {
|
|
|
5240
5240
|
const ENGINE = "/api/superadmin/engine-settings";
|
|
5241
5241
|
const LETTERPRESS = "/api/superadmin/letterpress";
|
|
5242
5242
|
const CODING_TELEMETRY = "/api/superadmin/coding-telemetry";
|
|
5243
|
+
const PULL_REQUESTS = "/api/superadmin/pull-requests";
|
|
5243
5244
|
const ENGINE_USAGE =
|
|
5244
5245
|
"Usage: admin letterpress status | gaps | telemetry [--days N] [--harness h] [--all-orgs] | prs [--days N | --from YYYY-MM-DD [--to YYYY-MM-DD] | --all-time] [--day YYYY-MM-DD] [--org id] [--state merged|open|closed] [--top N] [--tz zone] [--all-orgs] | blocked [--days N] [--org id] [--all-orgs] | unblock <org-id> <host> <subject> | decisions <org-id> [--site host] [--surface plan|fix|build|site] | undo <org-id> <host> <decision-id> | runs [--status s] [--error-code c] [--first-review-cause agent|context|setup|unknown] [--pr merged|closed|open|none] [--harness h] [--days N] | beyond [--limit N] [--before ISO] | companies | company <org-id> [--site host] | facts <org-id> [--site host] | fits [--recipe id] [--org id] [--site host] [--fits yes|no|unknown|waiting] [--limit N] | replay <run-id> | mark <run-id> <item-id> <right|weak|wrong|lead|gap|recipe|clear> [--note …] | settings | set <weights.<ask>.<reading>|lenses.<lens>.bar.<reading>|lenses.<lens>.bar|lenses.<lens>.research.turns|lenses.<lens>.research.ms|asks.<lens>.ask|asks.<lens>.guidance|dismissals.block_days|preflight.off|explore.ask|explore.research.turns|explore.research.ms|explore.every_days> <value>";
|
|
5245
5246
|
|
|
@@ -5487,7 +5488,8 @@ async function cmdAdminLetterpress(ctx) {
|
|
|
5487
5488
|
case "prs": {
|
|
5488
5489
|
// get_pull_requests (the days) or, with --day / --org / --state, list_pull_requests (the PRs behind them).
|
|
5489
5490
|
const listing = flags.day || flags.org || flags.state;
|
|
5490
|
-
const q = new URLSearchParams({
|
|
5491
|
+
const q = new URLSearchParams({ days: String(flags.days ?? 30) });
|
|
5492
|
+
if (listing) q.set("view", "list");
|
|
5491
5493
|
for (const [flag, key] of [
|
|
5492
5494
|
["day", "day"],
|
|
5493
5495
|
["org", "org_id"],
|
|
@@ -5501,7 +5503,7 @@ async function cmdAdminLetterpress(ctx) {
|
|
|
5501
5503
|
if (flags[flag]) q.set(key, String(flags[flag]));
|
|
5502
5504
|
if (flagBool(flags["all-orgs"])) q.set("customers", "0");
|
|
5503
5505
|
if (flagBool(flags["all-time"])) q.set("all_time", "1");
|
|
5504
|
-
const r = await staffRequest(ctx, "GET", `${
|
|
5506
|
+
const r = await staffRequest(ctx, "GET", `${PULL_REQUESTS}?${q}`);
|
|
5505
5507
|
const pct = (v) => (v == null ? "—" : `${Math.round(100 * v)}%`);
|
|
5506
5508
|
printResult(io, flags, r, (x) =>
|
|
5507
5509
|
listing
|