@letterstory/cli 0.177.131 → 0.177.133
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/log.mjs +4 -3
- package/package.json +1 -1
package/lib/cli.mjs
CHANGED
|
@@ -93,7 +93,7 @@ import {
|
|
|
93
93
|
import { fetchParkedSections, withoutParked } from "./parked.mjs";
|
|
94
94
|
|
|
95
95
|
// Matches cli/package.json; publish-cli.yml rewrites both to the published version.
|
|
96
|
-
export const VERSION = "0.177.
|
|
96
|
+
export const VERSION = "0.177.133";
|
|
97
97
|
|
|
98
98
|
/** The exit code for a gate refusal (CARD_REQUIRED, PAYMENT_FAILED, OUT_OF_TOKENS): 1 is a plain error. */
|
|
99
99
|
export const EXIT_PAYMENT_REQUIRED = 3;
|
package/lib/commands/log.mjs
CHANGED
|
@@ -1,18 +1,19 @@
|
|
|
1
1
|
// `log` — the Log from a terminal (docs/architecture/letter-log.md): what Letter did for the org, newest first.
|
|
2
2
|
// A thin wrapper over get_letter_log, the function the app's Log page calls.
|
|
3
3
|
//
|
|
4
|
-
// letterstory log [--limit <n>] [--before <ISO>]
|
|
4
|
+
// letterstory log [--kinds published,change_merged] [--goal seo|geo|agent_conviction|inbound_conversion] [--limit <n>] [--before <ISO>]
|
|
5
5
|
// letterstory log --all-orgs [--with-internal] staff: every org's (get_global_log)
|
|
6
6
|
|
|
7
7
|
import { argsFromFlags, printResult } from "./shared.mjs";
|
|
8
8
|
|
|
9
9
|
const page = {
|
|
10
|
+
kinds: { flag: "kinds", type: "list" },
|
|
10
11
|
limit: { flag: "limit", type: "num" },
|
|
11
12
|
before: { flag: "before" },
|
|
12
13
|
};
|
|
13
14
|
|
|
14
15
|
export const ARGS = {
|
|
15
|
-
get_letter_log: page,
|
|
16
|
+
get_letter_log: { ...page, goal: { flag: "goal" } },
|
|
16
17
|
get_global_log: { ...page, customer_only: { flag: "with-internal", type: "bool", invert: true } },
|
|
17
18
|
};
|
|
18
19
|
|
|
@@ -28,7 +29,7 @@ export async function cmdLog(ctx) {
|
|
|
28
29
|
[
|
|
29
30
|
...r.entries.map(
|
|
30
31
|
(e) =>
|
|
31
|
-
`${e.at.slice(0, 16).replace("T", " ")} ${e.action}${e.title ? ` ${e.title}` : ""}${e.by ? ` (${e.by})` : ""}${e.org ? ` [${e.org.name ?? e.org.id}]` : ""}`
|
|
32
|
+
`${e.at.slice(0, 16).replace("T", " ")} ${e.action}${e.title ? ` ${e.title}` : ""}${e.destination ? ` → ${e.destination}` : ""}${e.by ? ` (${e.by})` : ""}${e.org ? ` [${e.org.name ?? e.org.id}]` : ""}`
|
|
32
33
|
),
|
|
33
34
|
...(r.next_before ? [`Older: letterstory log --before ${r.next_before}`] : []),
|
|
34
35
|
].join("\n") || "Nothing yet"
|