# Pane configuration

Source: https://libtmux.org/en/csharp/latest/workspace/configuration/panes/

> Choose pane commands, launch settings and focus.

Each entry in a window's `panes` list describes one pane. A string is a command;
`null` leaves a blank shell pane. A mapping provides launch and command settings.

```yaml title="panes.yaml"
session_name: panes-example
windows:
  - window_name: work
    layout: even-horizontal
    panes:
      - null
      - shell: /bin/sh
        focus: true
        shell_command:
          - printf ready
          - printf second
```

The second pane launches `/bin/sh`, receives both commands in order and becomes
the active pane. A command list inside one pane does not create extra panes.

## Overrides

- `start_directory` overrides the inherited working directory.
- `shell` overrides the window's launch command.
- `environment` supplies the pane's launch environment map.
- `shell_command_before` adds setup after session and window setup.
- `enter`, `sleep_before` and `sleep_after` supply command defaults.
- `suppress_history` overrides the inherited history policy.

Set focus explicitly when automation depends on which pane is selected. Use
returned pane IDs for later operations instead of assuming that creation order
is a stable tmux ID.

Read [commands](https://libtmux.org/en/csharp/latest/workspace/configuration/commands/) for Enter and delay behavior and
[environment](https://libtmux.org/en/csharp/latest/workspace/configuration/environment/) for variable handling.

[CLI source](https://github.com/libtmux/libtmux-dotnet/blob/f77fe776ba67a04abb20ddbbc26cf4a000d63b74/src/LibTmux.Workspace.Cli/README.md).
