# exc.TmuxCommandError

- **Module:** exc
- **Package:** @libtmux/libtmux
- **Language:** TypeScript
- **Kind:** class
- **Source:** https://github.com/libtmux/libtmux-ts/blob/2cb93308200da38a26b59876618116850f110607/packages/libtmux/src/exc.ts#L362
- **Page:** https://libtmux.org/reference/ts/exc-tmuxcommanderror/

A tmux command that exited non-zero.

The parts are fields rather than a formatted sentence so callers can branch
on them. Matching a message substring is the failure mode this replaces: it
breaks silently when tmux rewords, and it cannot distinguish "already in the
requested state" from a genuine error.

## Members

- `args` (attribute)
- `exitCode` (attribute)
- `stderr` (attribute)
- `stdout` (attribute) — Whatever the command printed before it failed.
- `target` (attribute)
- `constructor` (method)
- `stderrIncludes` (method) — Whether tmux's own message contains a phrase, without message parsing at call sites.
