# libtmux.Server:get_option

- **Module:** libtmux
- **Package:** libtmux
- **Language:** Lua
- **Kind:** method
- **Source:** https://github.com/libtmux/libtmux-lua/blob/d68f829fe097e38dcbbf7147e276666fe615f0cf/lua/libtmux/_internal/server.lua#L737
- **Page:** https://libtmux.org/en/lua/v0.1.1/reference/libtmux-server-get_option/

```
get_option: fun(
  self: libtmux.Server,
  name: string,
  options?: libtmux.SettingGetOptions,
):libtmux.Request<libtmux.OptionRecord>
```

## Parameters

- `name` (`string`)
- `options` (`libtmux.SettingGetOptions?`)

## tmux command

The tmux commands behind `get_option`.

- [`show-options`](/en/tmux/latest/manual/show-options/)

## tmux C API

The C declarations in tmux that implement these commands.

- [`cmd_show_options_entry`](/en/tmux/latest/reference/c-variable-cmd_show_options_entry/) (attribute)
- [`cmd_show_options_exec`](/en/tmux/latest/reference/c-function-cmd-show-options-c-cmd_show_options_exec/) (function)

## tmux options

Settings for the server, sessions, windows and panes, with their types, defaults and allowed values.

- [Options](/en/tmux/latest/catalog/options/) (option)

## In other ports

Read one server option

| Language | Equivalent |
| --- | --- |
| Python | [`libtmux.Server.show_option`](/en/py/latest/reference/libtmux-server-show_option/) (method) |
| TypeScript | no single-option read; `Server.showOptions` returns them all |
| Rust | [`server.Server.typed_option`](/en/rs/latest/reference/server-server-typed_option/) (method) |
| Go | [`tmux.Server.RawOption`](/en/go/latest/reference/tmux-server-rawoption/) (method) |
| Java | reached through `Server.options`, whose `Options.get` reads one |
| C# | reached through `Server.Options`, whose `TmuxOptions.GetAsync` reads one |
| C++ | no single-option read; `Server::options` returns them all |
| Swift | [`Server.option(_:scope:)`](/en/swift/latest/reference/server-option(_-scope-)/) (method) |

No equivalent is recorded in Ruby, PowerShell, Julia, Elixir, Kotlin, Scala or F#.
