File tree Expand file tree Collapse file tree 1 file changed +5
-1
lines changed Expand file tree Collapse file tree 1 file changed +5
-1
lines changed Original file line number Diff line number Diff line change 1+ """CLI for ``tmuxp convert`` subcommand."""
12import argparse
23import os
34import pathlib
1617def create_convert_subparser (
1718 parser : argparse .ArgumentParser ,
1819) -> argparse .ArgumentParser :
20+ """Augment :class:`argparse.ArgumentParser` with ``convert`` subcommand."""
1921 workspace_file = parser .add_argument (
2022 dest = "workspace_file" ,
2123 type = str ,
@@ -40,6 +42,8 @@ def create_convert_subparser(
4042
4143
4244class ConvertUnknownFileType (exc .TmuxpException ):
45+ """Raise if tmuxp convert encounters an unknown filetype."""
46+
4347 def __init__ (self , ext : str , * args : object , ** kwargs : object ) -> None :
4448 return super ().__init__ (
4549 f"Unknown filetype: { ext } (valid: [.json, .yaml, .yml])"
@@ -51,7 +55,7 @@ def command_convert(
5155 answer_yes : bool ,
5256 parser : t .Optional [argparse .ArgumentParser ] = None ,
5357) -> None :
54- """Convert a tmuxp config between JSON and YAML."""
58+ """Entrypoint for ``tmuxp convert`` convert a tmuxp config between JSON and YAML."""
5559 workspace_file = find_workspace_file (
5660 workspace_file , workspace_dir = get_workspace_dir ()
5761 )
You can’t perform that action at this time.
0 commit comments