server.Server.access_rules
Rust
- Python Unavailable
- Ruby Unavailable
- Lua Unavailable
- TypeScript Unavailable
- Rust
- Go Unavailable
- Java Unavailable
- .NET Unavailable
- C++ Unavailable
- Swift Unavailable
- Module
- server
- Declared in
- Server
- Package
- libtmux
- Source
- crates/libtmux/src/server.rs
-
The users on this server's access list.
The owner is always present and always writable, and tmux refuses to change their entry, so a caller cannot lock itself out.
Errors
Returns
Error::UnsupportedCapabilitybelow tmux 3.3, and an error when tmux cannot be reached or refuses the listing.Examples
let guard = libtmux::test::TestServer::new().await?;let version = guard.server().capabilities().await?.tmux_version().clone();// Whoever started the server owns it and may act.if version.has_behavior(&libtmux::since::SERVER_ACCESS) {let rules = guard.server().access_rules().await?;assert_eq!(rules.len(), 1);assert_eq!(rules[0].mode(), libtmux::AccessMode::Write);}guard.shutdown().await?;
0 declared, 0 inherited