Core Library0.xAPI Reference

Choose documentation 3

latest

Current version

latest
English

Early release libtmux is released, and its APIs may still change between releases. This site's structure and URLs may change too.

method libtmux-ts latest

Server.equals

Whether other is a handle addressing the same tmux server.

Source and package
Qualified name
Server.equals
Module
server
Declared in
Server
Package
libtmux
Source
packages/libtmux/src/server.ts

Description#

Compared by the socket the connection resolves to rather than by object identity, so a server constructed twice against one socket is equal to itself. A socket name is not that socket: tmux resolves -L work under TMUX_TMPDIR, so the same name with two different tmpdirs addresses two different daemons, and this reports them as different. Accepts unknown because the interesting comparisons are against values a caller has not narrowed yet.

Examples#

server.equals(new Server({ socketPath: server.socketPath ?? "" }));
Parameters
Esc

Type to search.

Reference previewOpen reference