SessionSpec
How a session should be made.
Source and package
- Qualified name
-
io.github .libtmux. Session Spec - Package
- io.github.libtmux
- Distribution
- io.github.libtmux:libtmux
- Source
- libtmux/src/main/java/io/github/libtmux/SessionSpec.java
-
Description#
The shape
SplitSpecandWindowSpecuse. tmux's-A, which attaches when the name is taken, is deliberately absent: attaching needs a terminal, and it fails withopen terminal failedon every supported release when there is none. AskingServer#hasSession()first does the same job from a process that has no tty, which is where a library usually runs.Examples#
Session build = server.newSession(s -> s.named("build").sized(new Dimensions(120, 40)));
Members14#
Common operations1#
- Builder class Collects the choices, each named for what it does rather than for the field it sets.
Other members13#
- argv method The command that makes this session, reporting it through
format. - builder method A builder holding tmux's own defaults: a detached session tmux names itself.
- clientFlags method Client flags, which tmux takes as one comma-separated list.
- command method What the session's first pane runs, empty for the default shell.
- detached method Always true, and not a choice.
- detachOthers method Whether other clients on this session are detached.
- directory method Where the session's first pane starts, or empty to inherit.
- environment method Variables set for the new session, in the order they were given.
- name method The session name, or empty to let tmux number it.
- size method How big the session is, or empty for tmux's default.
- toString method
- windowName method The name of the session's first window, or empty for tmux's choice.
- withoutSize method Whether tmux is told not to give the session a size at all.