Jeden/Docs

CLI command

jeden sessions

List locally stored Jeden session identifiers.

Exact invocation#

Shell
jeden sessions [limit] [--json]

Inputs and options#

  • Optional: a whole-number positional limit, including zero for no rows; it keeps the newest sessions, as jeden sessions search's limit does. With no limit, every directory in the session root is considered.
  • Optional: --json prints the identifiers as one JSON array.
  • The session root is ~/.jeden/sessions unless JEDEN_SESSION_ROOT overrides it.

Output and state effect#

Reads session directory names and prints one per line, newest first (a session directory is named for the second it began), or the JSON array in that order; it does not mutate session data. A root that does not exist prints No sessions found. (or []).

Refusals and boundaries#

  • The functionality is jeden.session.list; jeden errors show jeden.session.list prints every cause with its test (tests/sessions/listing/list.mjs). Before the root is read, each exit 2: limit-invalid (sessions takes a whole number of sessions to list, and `VALUE` is not one) and argument-unexpected (sessions takes one whole number, and `ARG` follows it).
  • root-unlistable, exit 1: cannot list sessions in PATH: it is no directory this user can list, or an entry of it cannot be read, observed: what the system answered.
  • A command line of the wrong form (an unknown command or option, a missing, unexpected or invalid argument, a missing confirmation) prints the error and the usage and exits 2; a refusal that retrying unchanged can help (a dependency down or not answering, a rate limit) exits 69; any other refusal or failure exits 1. A refusal a functionality declares ends with fix: … and cause: <operation>.<cause>, and jeden errors show <operation> lists every cause of that functionality.