libtmux Reference MCP Search
On this page

libtmux.Server.source_file

View as Markdown

Module
libtmux
Declared in
Server
Package
libtmux
Source
src/libtmux/server.py
source_file ( self , path : StrPath , quiet : bool | None = None , parse_only : bool | None = None , verbose : bool | None = None ) None
method [source]
method [source]
source_file

Source a tmux configuration file via $ tmux source-file.

Examples

>>> import pathlib
>>> conf = pathlib.Path(request.config.rootdir) / '..' / 'tmp_src.conf'
>>> _ = conf.write_text('set -g @test_source yes')
>>> server.source_file(str(conf))
Parameters
  • path ( StrPath ) – Path to the configuration file.

  • quiet ( bool | None ) – Suppress errors for missing files (-q flag).

  • parse_only ( bool | None ) – Check syntax only, do not execute (-n flag).

  • verbose ( bool | None ) – Show parsed commands (-v flag).

0 declared, 0 inherited

Esc

Type to search.