From 3aaf203cebda39750fb1380689469f1724e18f65 Mon Sep 17 00:00:00 2001 From: Psychpsyo <60073468+Psychpsyo@users.noreply.github.com> Date: Fri, 19 Jul 2024 22:18:09 +0200 Subject: [PATCH 1/2] Fix typo in README (#650) --- README.rst | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/README.rst b/README.rst index 0e2121c..cfcebc2 100644 --- a/README.rst +++ b/README.rst @@ -100,4 +100,4 @@ Disclaimer None of the vendors cited in this project agree or endorse any of the patterns or implementations. -Its names are used only to maintain context. +Their names are used only to maintain context. From 99501cc2c1d21ea156b8b8b530ad66c9c9d00fe3 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Benito=20L=C3=B3pez?= Date: Fri, 19 Jul 2024 22:23:52 +0200 Subject: [PATCH 2/2] New feature: Software columns - Part 2: CLI (#649) * Add software_columns CLI parameter * Fix sorting --------- Co-authored-by: Patrick Kanzler <4189642+patkan@users.noreply.github.com> --- src/escpos/cli.py | 32 ++++++++++++++++++++++++++++++++ 1 file changed, 32 insertions(+) diff --git a/src/escpos/cli.py b/src/escpos/cli.py index f70d922..2906c16 100644 --- a/src/escpos/cli.py +++ b/src/escpos/cli.py @@ -209,6 +209,38 @@ ESCPOS_COMMANDS: List[Dict[str, Any]] = [ }, ], }, + { + "parser": { + "name": "software_columns", + "help": "Print a list of texts arranged into columns", + }, + "defaults": { + "func": "software_columns", + }, + "arguments": [ + { + "option_strings": ("--text_list",), + "help": "list of texts to print", + "nargs": "+", + "type": str, + "required": True, + }, + { + "option_strings": ("--widths",), + "help": "list of column widths", + "nargs": "+", + "type": int, + "required": True, + }, + { + "option_strings": ("--align",), + "help": "list of column alignments", + "nargs": "+", + "type": str, + "required": True, + }, + ], + }, { "parser": { "name": "cut",