zele 0.3.12 → 0.3.14

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/src/output.ts CHANGED
@@ -212,17 +212,22 @@ export function printYaml(data: unknown): void {
212
212
  }
213
213
 
214
214
  /**
215
- * Print a list of items as YAML with optional pagination.
215
+ * Print a list of items as YAML with optional pagination and summary.
216
216
  * Output shape:
217
+ * summary: "5 threads (inbox)"
217
218
  * items:
218
219
  * - key: value
219
220
  * next_page: "token"
220
221
  */
221
222
  export function printList(
222
223
  items: Record<string, unknown>[],
223
- opts?: { nextPage?: string | null },
224
+ opts?: { nextPage?: string | null; summary?: string },
224
225
  ): void {
225
- const doc: Record<string, unknown> = { items }
226
+ const doc: Record<string, unknown> = {}
227
+ if (opts?.summary) {
228
+ doc.summary = opts.summary
229
+ }
230
+ doc.items = items
226
231
  if (opts?.nextPage) {
227
232
  doc.next_page = opts.nextPage
228
233
  }
package/bin/zele DELETED
@@ -1,27 +0,0 @@
1
- #!/usr/bin/env sh
2
- # Shell launcher for zele CLI.
3
- # Prefers bun (required for the TUI), falls back to node for non-TUI commands.
4
- # Uses exec so no child process is spawned — the shell is replaced in-place.
5
- #
6
- # Shebang uses "#!/usr/bin/env sh" instead of "#!/bin/sh" so that npm's
7
- # cmd-shim on Windows captures "sh" as the program name (looked up via PATH)
8
- # rather than the literal "/bin/sh" path which doesn't exist on Windows.
9
- # Git for Windows provides sh.exe on PATH, making this work cross-platform.
10
-
11
- # Resolve symlink (npm/pnpm create symlinks for bin entries)
12
- SELF="$0"
13
- if [ -L "$SELF" ]; then
14
- LINK="$(readlink "$SELF")"
15
- case "$LINK" in
16
- /*) SELF="$LINK" ;;
17
- *) SELF="$(dirname "$SELF")/$LINK" ;;
18
- esac
19
- fi
20
- DIR="$(cd "$(dirname "$SELF")" && pwd)"
21
- CLI="$DIR/../dist/cli.js"
22
-
23
- if command -v bun >/dev/null 2>&1; then
24
- exec bun "$CLI" "$@"
25
- else
26
- exec node "$CLI" "$@"
27
- fi