Core Library0.xAPI Reference

Choose documentation 2

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.

cmdlet libtmux-powershell latest

LibTmux.Split-TmuxPane

Split an explicit pane and return the newly created pane.

Source and package
Qualified name
LibTmux\Split-TmuxPane
Declared in
LibTmux
Package
LibTmux
Source
src/LibTmux.PowerShell/SplitTmuxPaneCommand.cs

Description#

Split a native Pane directly or through the pipeline. By default the new pane is below its target and remains unselected. Horizontal chooses a left/right split; Before places the new pane above or left of the target. Success returns the captured native LibTmux.Pane for the new pane and does not refresh the original handle in place.

Notes

WhatIf performs no core discovery or dispatch and emits no pane. Confirmation precedes the core operation. The caller remains responsible for the created pane and its process. Cancellation is not rollback and no mutation is retried. Per-owner errors use Tmux.PaneSplitFailed and retain the core exception and failed pane. ErrorAction Continue allows later owners to run. The core and tmux enforce geometry and version capabilities.

Command details#

Command type
cmdlet
Default parameter set
Cells
Confirmation
Supports -WhatIf and -Confirm; confirm impact: Medium.
Positional binding
Enabled.
Pipeline inputs
LibTmux.Pane: Native pipeline type for this command.
Outputs
LibTmux.Pane

Examples#

Example 1 Place a new twenty-column pane to the left of the first pane on the server identified by $SocketPath. The window must have enough room. The current pane selection is preserved; the new /bin/sh process remains running until you remove its pane. View source

Terminal window
LibTmux\New-TmuxServer -SocketPath $SocketPath |
LibTmux\Get-TmuxPane | Select-Object -First 1 |
LibTmux\Split-TmuxPane -Horizontal -Before -Size 20 -Command 'exec /bin/sh'
Parameters
Common parameters 12

PowerShell supplies these parameters. See common parameter behavior for their effects.

Returns

LibTmux.Pane: Captured native object for the created resource.

tmux command#

The tmux commands behind Split-TmuxPane.

tmux C API#

The C declarations in tmux that implement these commands.

Each path starts at a function a command runs, which is degree 1. The degree counts steps from there along the path, and each step is a call or a reference: degree 2 is reached from that function, degree 3 from the next, and so on.

Split a window

  1. 1 cmd_split_window_exec
  2. references → 2 spawn_pane
  3. calls → 3 window_add_pane
  4. calls → 4 window_pane_create

Guides#

Pages that discuss Split-TmuxPane.

Esc

Type to search.

Reference previewOpen reference