Skip to content

Commit a07a8fb

Browse files
committed
Updates to CLI documentation
1 parent eb18c97 commit a07a8fb

File tree

2 files changed

+25
-14
lines changed

2 files changed

+25
-14
lines changed

doc/cli.rst

Lines changed: 25 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -57,30 +57,37 @@ Import
5757
From teamocil
5858
'''''''''''''
5959

60-
.. code-block:: bash
61-
62-
$ tmuxp import teamocil <filename>
60+
.. argparse::
61+
:module: tmuxp.cli
62+
:func: get_parser
63+
:prog: tmuxp
64+
:path: import teamocil
6365

6466
.. _import_tmuxinator:
6567

6668
From tmuxinator
6769
'''''''''''''''
6870

69-
.. code-block:: bash
70-
71-
$ tmuxp import tmuxinator <filename>
71+
.. argparse::
72+
:module: tmuxp.cli
73+
:func: get_parser
74+
:prog: tmuxp
75+
:path: import tmuxinator
7276

7377
.. _convert_config:
7478

7579
Convert between YAML and JSON
7680
"""""""""""""""""""""""""""""
7781

78-
.. code-block:: bash
82+
.. argparse::
83+
:module: tmuxp.cli
84+
:func: get_parser
85+
:prog: tmuxp
86+
:path: load
7987

80-
$ tmuxp convert <filename>
8188

82-
tmuxp automatically will prompt to convert ``.yaml`` to ``.json`` and
83-
``.json`` to ``.yaml``.
89+
tmuxp automatically will prompt to convert ``.yaml`` to ``.json`` and
90+
``.json`` to ``.yaml``.
8491

8592
.. _bash_completion:
8693

@@ -105,14 +112,19 @@ For zsh, ``.zshrc``:
105112
106113
$ source tmuxp.zsh
107114
108-
109115
.. _commands:
110116

111-
Commands
112-
""""""""
117+
Other commands
118+
""""""""""""""
113119

114120
.. argparse::
115121
:module: tmuxp.cli
116122
:func: get_parser
117123
:prog: tmuxp
124+
:path: kill-session
118125

126+
.. argparse::
127+
:module: tmuxp.cli
128+
:func: get_parser
129+
:prog: tmuxp
130+
:path: attach-session

tmuxp/cli.py

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -685,7 +685,6 @@ def command_kill_session(args):
685685
except Exception as e:
686686
logger.error(e)
687687

688-
689688
def get_parser():
690689
"""Return :py:class:`argparse.ArgumentParser` instance for CLI."""
691690

0 commit comments

Comments
 (0)