Skip to content

Commit 43afa61

Browse files
committed
refactor(cli): Rename config to workspace
1 parent ce01c82 commit 43afa61

File tree

2 files changed

+8
-8
lines changed

2 files changed

+8
-8
lines changed

src/tmuxp/cli/__init__.py

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -68,12 +68,12 @@ def create_parser() -> argparse.ArgumentParser:
6868
)
6969
create_shell_subparser(shell_parser)
7070
import_parser = subparsers.add_parser(
71-
"import", help="import configurations from teamocil and tmuxinator."
71+
"import", help="import workspaces from teamocil and tmuxinator."
7272
)
7373
create_import_subparser(import_parser)
7474

7575
convert_parser = subparsers.add_parser(
76-
"convert", help="convert configs between yaml and json."
76+
"convert", help="convert workspace files between yaml and json."
7777
)
7878
create_convert_subparser(convert_parser)
7979

@@ -82,14 +82,14 @@ def create_parser() -> argparse.ArgumentParser:
8282
)
8383
create_debug_info_subparser(debug_info_parser)
8484

85-
ls_parser = subparsers.add_parser("ls", help="list sessions in config directory")
85+
ls_parser = subparsers.add_parser("ls", help="list workspaces in tmuxp directory")
8686
create_ls_subparser(ls_parser)
8787

88-
edit_parser = subparsers.add_parser("edit", help="run $EDITOR on config")
88+
edit_parser = subparsers.add_parser("edit", help="run $EDITOR on workspace file")
8989
create_edit_subparser(edit_parser)
9090

9191
freeze_parser = subparsers.add_parser(
92-
"freeze", help="freeze a live tmux session to a tmuxp config"
92+
"freeze", help="freeze a live tmux session to a tmuxp workspace file"
9393
)
9494
create_freeze_subparser(freeze_parser)
9595

src/tmuxp/cli/convert.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -58,15 +58,15 @@ def command_convert(
5858
newfile = workspace_file.parent / (str(workspace_file.stem) + f".{to_filetype}")
5959

6060
export_kwargs = {"default_flow_style": False} if to_filetype == "yaml" else {}
61-
new_config = configparser.dump(format=to_filetype, indent=2, **export_kwargs)
61+
new_workspace = configparser.dump(format=to_filetype, indent=2, **export_kwargs)
6262

6363
if not answer_yes:
6464
if prompt_yes_no(f"Convert to <{workspace_file}> to {to_filetype}?"):
65-
if prompt_yes_no("Save config to %s?" % newfile):
65+
if prompt_yes_no("Save workspace to %s?" % newfile):
6666
answer_yes = True
6767

6868
if answer_yes:
6969
buf = open(newfile, "w")
70-
buf.write(new_config)
70+
buf.write(new_workspace)
7171
buf.close()
7272
print(f"New config saved to <{newfile}>.")

0 commit comments

Comments
 (0)