Workspace ManagerAPI Reference

Choose documentation 3

latest

Current version

latest
English

Prerelease This site documents an alpha of libtmux. Its structure, URLs and APIs are subject to change.

LibTmuxWorkspace.run_before_script

Methods#

Execute shlex-style argv without implicit shell evaluation. Relative executable paths containing / resolve from the configuration base; bare names use PATH. Explicit /bin/sh -c remains an intentional shell command. Pipes are drained concurrently with bounded captures; on_output(stream, bytes) receives owned chunks and must return promptly. Its calls are serialized across both streams.

run_before_script(text; base_directory, start_directory=base_directory,
env=ENV, timeout=0.9, cancel=nothing, on_output=nothing,
max_output_bytes=65536, max_error_bytes=65536)

Cancellation/deadline kill the directly owned process and its still-owned POSIX process group. The direct child is reaped on every path. Descendants that leave the group, or outlive successful script exit with redirected output, are external script effects; their exit is not established. The same monotonic deadline bounds inherited open pipes after direct-child exit. No output appears in errors.

Parameters
Esc

Type to search.

Reference preview Open reference