libtmux.Server.show_prompt_history
- Module
- libtmux
- Declared in
- Server
- Package
- libtmux
- Source
- src/libtmux/server.py
- Other languages
- Ruby Lua TypeScript RustGoJava.NET C++ Swift
-
Show prompt history via
$ tmux show-prompt-history.In other ports Read what has been typed at command prompts
- Ruby No source-verified Ruby equivalent is recorded for this operation.
- Lua No source-verified Lua equivalent is recorded for this operation.
- TypeScript no equivalent on
Server - Rust
server.Server.prompt_history - Go
tmux.Server.ShowPromptHistory - Java
io.github.libtmux.Server.Server.promptHistory - .NET
LibTmux.Server.GetPromptHistoryAsync - C++ no equivalent on
Server - Swift no equivalent on
Server
Examples
>>> from libtmux.common import has_gte_version>>> if has_gte_version("3.3"):... result = server.show_prompt_history()... else:... result = []>>> isinstance(result, list)Trueuse libtmux::PromptKind;
let guard = libtmux::test::TestServer::new().await?;let server = guard.server();let version = server.capabilities().await?.tmux_version().clone();
// A fresh server has answered no prompts.if version.has_behavior(&libtmux::since::PROMPT_HISTORY) { assert!(server.prompt_history(PromptKind::Command).await?.is_empty());}
guard.shutdown().await?;0 declared, 0 inherited