On this page
tmux.NewSessionRequest
- Module
- tmux
- Package
- github.com/libtmux/libtmux-go/tmux
- Source
- tmux/session_lifecycle.go
-
NewSessionRequest configures session creation.
Server.NewSessioncreates a detached session;Server.NewSessionConnectioncreates one attached to its first control-mode lane. Its zero value uses tmux defaults. Width and Height are either zero or 1 through 65535; KillExisting requires Name. KillExisting may remove a session before a later creation failure.Server.NewSessioncopies Environment before validation and retains no map storage; concurrent mutation during the copy is unsafe. Foreground-only tmux flags are not exposed.
8 declared, 0 inherited
Members
- Command attribute Command starts the initial pane with this shell command; empty uses tmux's default command.
- Environment attribute Environment is emitted in lexically sorted key order. The map is not retained; nil and an empty map both add no entries.
- Height attribute Height sets the detached session height; zero lets tmux choose.
- KillExisting attribute KillExisting removes an existing session named Name before creation.
- Name attribute Name selects the new session name; empty lets tmux generate one.
- StartDirectory attribute StartDirectory expands ~ and ~/... for the current user. Named-user forms such as ~other are rejected; empty inherits tmux's default.
- Width attribute Width sets the detached session width; zero lets tmux choose.
- WindowName attribute WindowName names the initial window; empty lets tmux choose.