# `TTYCast.Recorder`

Records commands running under a real pseudo-terminal.

This module is for non-interactive command recording: output from the child PTY
is captured into a `.ttycast` file until the process exits or the optional
timeout elapses.

# `result`

```elixir
@type result() :: %{
  status: non_neg_integer(),
  path: Path.t(),
  bytes: non_neg_integer()
}
```

# `record`

```elixir
@spec record(
  [String.t()],
  keyword()
) :: {:ok, result()} | {:error, term()}
```

Records `[cmd | args]` under a PTY and writes the result to `opts[:path]`.

---

*Consult [api-reference.md](api-reference.md) for complete listing*
