finding stored runs and their output
On this page
Every command executed through awa run is recorded, and its output is stored
durably whether the run was cacheable or not — as long as capture is on, which it
is by default. A project that sets [run].capture_output = false still gets the
run in the history, but with nothing to read (reuse reason capture-disabled).
This page is how you find a run again and read what it printed — instead of
re-running it, or redirecting to a scratch file you will have to remember the name
of.
Find the run
awa run log
awa run log -n 10
awa run log --command <substring>
awa run ls
awa run ls --all
<substring> is literal and case-sensitive, and matches anywhere in the recorded
command line — the executable or its arguments, joined by single spaces — so
--command "xtask check" finds cargo xtask check.
Listing rows show the command as a one-line preview: line breaks, control and
bidirectional-text characters are escaped, and a long command ends in …. That shortens only the
display, not stored output; --command still matches the original text.
awa run show <id> and awa run rm print the whole command with the same escapes
and no …. That text is for reading, not a shell command to copy: the exact
arguments are in --json.
awa run log is chronological history, newest first: everything that was
recorded, including failed, mutating, and record-only runs. awa run ls is a
different question — which stored runs are reusable for the current state — so
a run missing from ls is not missing from history. awa run ls --all lists the
non-reusable ones too, each with its reason token. When nothing is reusable,
ls adds a history: pointer to run log. To find an earlier execution,
use run log --command, not ls or run explain: a failed, mutating, or
record-only run is still readable evidence, and reading it needs no cache-policy
change.
A run whose validation policy has approved identity probes
that only awa run executes may be listed apart as unassessed, also with
--all: its reuse is unknown, neither reusable nor non-reusable. Without the
approval, or when another reason already decides, the run is assessed as usual.
The JSON form is in awa help json.
There is no time-range filter. To find a run from a particular moment, narrow
with --command and read the timestamps, choosing how they are rendered with
--time relative, --time local, or --time utc.
awa run log takes its default rendering from the [ui] config table, so a
project that prefers absolute timestamps sets it once instead of passing --time
every call. awa run show is the exception: it reads stored records only and
loads no configuration, so its default stays relative whatever [ui] says.
--json is unaffected either way — machine output is always UTC.
Read the output
awa run show <id>
awa run show <id> --tail 500
awa run show <id> --grep "<pattern>"
awa run show <id> --stdout
awa run show <id> --stderr
awa run show --last --tail 500
<id> is a run id (a unique prefix is enough) and <pattern> is a regular
expression. Exactly one of an id or --last selects the run. --last is a
convenience for the newest readable run, which moves whenever anyone records
another run in this project; keep the id when referring to a result. Ids belong
to this project's .awa/ store, so show from another project does not find
them: the not-found message names the project root it searched. Read another
project's run with --root <path>.
- Plain
showand--metaprint metadata only, never captured output: command, cwd, exit, duration, cacheability, reuse state, mutation outcome, key, and per-stream byte counts. Read output with one of the forms below. --stdoutand--stderrwrite one raw stream and nothing else, so they are safe to pipe. Captured bytes are never escaped.--tail <n>and--grep <pattern>filter what is shown; combined with a stream selector they filter that stream, otherwise both streams are shown under labelled headers. A tailed view says(tail — earlier lines omitted)so a partial view is never mistaken for the whole log.
awa run show reads stored records only. It never scans the current worktree and
never loads project configuration, so it keeps working when the tree has moved on
or a config file is malformed.
Filter stored output, not the live run
The run id and exit are in the footer awa run writes to stderr. Filtering both
live streams — awa run -- <command> 2>&1 | grep <pattern>, or 2>&1 | tail —
can drop that footer. Any pipe, with or without 2>&1, normally leaves the
shell's status for the pipeline as the last command's: the filter's, not awa's
or the wrapped command's. That is shell behavior, and pipefail is not
available in every shell. Keep the result first, then filter the stored copy:
awa run --record -- <command> # unfiltered; note run id and exit
awa run show <run-id> # metadata: the stored exit
awa run show <run-id> --grep "<pattern>" # matching captured lines
A successful run show means the record was read, matches or not; the stored
command's result is its exit: line (data.execution.exit in --json). Lost
an id? Find the execution again with awa run log --command "<text>".
Recovering an id does not recover output that was truncated, never captured,
or has expired.
What the evidence does and does not prove
Stored output is evidence of what that execution printed at that time. It is not a statement about the current state, and reading it is not the same as re-running the command.
awa run show --json is metadata by default and reports each stream's integrity
as unverified: the record was inspected, but no payload bytes were opened.
Integrity becomes verified for a stream only when an explicit --tail or
--grep read opens it and checks it against its recorded hash — and a stream
that fails that check is a loud error, never a document quietly claiming
verified. A stream you did not select stays unverified.
Output beyond the capture limit is stored truncated, and every surface says so
with the omitted byte count ((stored <n>, <n> omitted)). A partial payload is
never presented as complete.
Captured stdout and stderr are stored verbatim and are never redacted, so a command that printed a secret stored that secret. See awa help privacy.
What changed during a run
Every stored run — a record-only one, an ordinary cached one, a failed one — has an observed state before and after it, usable as state references:
awa changes run:<id>:before..run:<id>:after
awa diff run:<id>:before..run:<id>:after
That answers "what observed state changed while it ran", the standard follow-up
after a record-only run. It does not name the writer: an edit made elsewhere
during the run shows up the same way, and a write undone before the run ended
or outside the observed scope does not show up at all. A run observation
records each observed file's hash, not its bytes, so diff reports a change that
needs a run's bytes as hash-only rather than inventing content, and cannot show a
temporary input after it is gone. Excluded and protected paths,
.awa/ included, are not observed at all. To keep an experiment's input readable, see
awa help agents.
Delete stored runs
awa run rm <id>
awa run rm --command <substring> --dry-run
awa run rm --older-than <duration>
<duration> accepts d, h, m, and s units, so 30d and 720h are both
valid. Explicit ids and the filter flags are mutually exclusive, and --dry-run
reports what would be removed without removing it. --command matches arguments
as well as the executable, so check its targets with --dry-run first.
Deleting a run deletes the evidence, not the effect: whatever the command did to the worktree stays done. For routine cleanup driven by policy rather than by hand, prefer awa help gc.
The wider timeline
awa log
awa log --all
awa log lists explicit checkpoints only. awa log --all interleaves recorded
runs and git commit boundaries as context markers — the commit boundaries are
markers, not awa state references.