# libtmux.Pane.show_option

- **Module:** libtmux
- **Package:** libtmux
- **Language:** Python
- **Kind:** method
- **Source:** https://github.com/tmux-python/libtmux/blob/38e368c11117fb4aeb2f082d552cd4f210eae06a/src/libtmux/options.py#L1241
- **Inherited from:** libtmux.options.OptionsMixin
- **Page:** https://libtmux.org/en/py/stable/reference/libtmux-pane-show_option/

tmux catalog: [Options](/en/tmux/latest/catalog/options/)

```
libtmux.Pane.show_option(
    self,
    option: str,
    global_: bool = False,
    g: bool = False,
    scope: OptionScope
    | _DefaultOptionScope
    | None = DEFAULT_OPTION_SCOPE,
    ignore_errors: bool | None = None,
    include_hooks: bool | None = None,
    include_inherited: bool | None = None,
) -> t.Any | None
```

Return option value for the target.

## Examples

```python
>>> import typing as t
>>> from libtmux.common import tmux_cmd
>>> from libtmux.constants import OptionScope
```

```python
>>> class MyServer(OptionsMixin):
...     socket_name = server.socket_name
...     def cmd(self, cmd: str, *args: object):
...         cmd_args: t.List[t.Union[str, int]] = [cmd]
...         if self.socket_name:
...             cmd_args.insert(0, f"-L{self.socket_name}")
...         cmd_args.insert(0, "-f/dev/null")
...         return tmux_cmd(*cmd_args, *args)
...
...     default_option_scope = OptionScope.Server
```

```python
>>> MyServer().cmd('new-session', '-d')
<libtmux.common.tmux_cmd object at ...>
```

```python
>>> MyServer().show_option('exit-unattached', global_=True)
False
```

## Parameters

- `option` (`str`)
- `global_` (`bool`)
- `g` (`bool`): Use ``global_`` instead. (deprecated 0.50.0)
- `scope` (`OptionScope | _DefaultOptionScope | None`)
- `ignore_errors` (`bool | None`)
- `include_hooks` (`bool | None`)
- `include_inherited` (`bool | None`)

## Raises

- [`exc.OptionError`](/en/py/stable/reference/libtmux-exc-optionerror/)
- [`exc.UnknownOption`](/en/py/stable/reference/libtmux-exc-unknownoption/)
- [`exc.InvalidOption`](/en/py/stable/reference/libtmux-exc-invalidoption/)
- [`exc.AmbiguousOption`](/en/py/stable/reference/libtmux-exc-ambiguousoption/)

## In other ports

### Read one pane option

- Lua: [`libtmux.Pane:get_option`](/en/lua/latest/reference/libtmux-pane-get_option/) (method)
- Rust: [`pane.Pane.typed_option`](/en/rs/latest/reference/pane-pane-typed_option/) (method)
- Go: [`tmux.Pane.RawOption`](/en/go/latest/reference/tmux-pane-rawoption/) (method)
- C++: [`libtmux::Pane::option`](/en/cxx/latest/reference/libtmux-pane-option/) (method)
- Swift: [`Server.option(_:scope:)`](/en/swift/latest/reference/server-option(_-scope-)/) (method)
