Skip to content

Commit ff5008a

Browse files
committed
docs(cli): Add tmuxp cli
1 parent bc1f377 commit ff5008a

File tree

1 file changed

+47
-0
lines changed

1 file changed

+47
-0
lines changed

docs/cli.rst

Lines changed: 47 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,53 @@ In zsh (``~/.zshrc``):
2222
2323
eval "$(_TMUXP_COMPLETE=source_zsh tmuxp)"
2424
25+
.. _cli_cli:
26+
27+
tmux CLI
28+
--------
29+
30+
::
31+
32+
tmuxp cli
33+
34+
tmuxp cli <session_name>
35+
36+
tmuxp cli <session_name> <window_name>
37+
38+
Launch into a `libtmux`_ session.
39+
40+
Automatically will picked the current tmux :class:`server <libtmux.Server>`,
41+
:class:`session <libtmux.Session>`, and :class:`window <libtmux.Window>` you
42+
are currently in. Pass additional arguments to select a specific one of your
43+
choice::
44+
45+
(Pdb) server
46+
<libtmux.server.Server object at 0x7f7dc8e69d10>
47+
(Pdb) server.sessions
48+
[Session($1 your_project)]
49+
(Pdb) session
50+
Session($1 your_project)
51+
(Pdb) session.name
52+
'your_project'
53+
(Pdb) window
54+
Window(@3 1:your_window, Session($1 your_project))
55+
(Pdb) window.name
56+
'your_window'
57+
(Pdb) window.panes
58+
[Pane(%6 Window(@3 1:your_window, Session($1 your_project)))
59+
60+
Python 3.7 supports `PEP 553`_'s ``PYTHONBREAKPOINT`` and supports
61+
compatible debuggers, for instance `ipdb`_:
62+
63+
.. code-block:: sh
64+
65+
pip install ipdb
66+
env PYTHONBREAKPOINT=ipdb.set_trace tmuxp cli
67+
68+
.. _PEP 553: https://www.python.org/dev/peps/pep-0553/
69+
.. _ipdb: https://pypi.org/project/ipdb/
70+
.. _libtmux: https://libtmux.git-pull.com
71+
2572
.. _cli_freeze:
2673

2774
Freeze sessions

0 commit comments

Comments
 (0)