diff options
author | Kevin Van Brunt <kmvanbrunt@gmail.com> | 2019-12-09 21:08:15 -0500 |
---|---|---|
committer | GitHub <noreply@github.com> | 2019-12-09 21:08:15 -0500 |
commit | bc99c90b4b4a8fd667b0ad77c9442d1393611f5f (patch) | |
tree | 7e612c633b9e54e35220b3690b8a5c2cd69000c3 /cmd2/parsing.py | |
parent | 0aac6cee56a92bb6358106329f4f0c20e85bb7bc (diff) | |
parent | a4427a3a905d9e926e1ab9c57716235229247912 (diff) | |
download | cmd2-git-bc99c90b4b4a8fd667b0ad77c9442d1393611f5f.tar.gz |
Merge pull request #831 from python-cmd2/align_text0.9.22
Added text alignment functions
Diffstat (limited to 'cmd2/parsing.py')
-rwxr-xr-x | cmd2/parsing.py | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/cmd2/parsing.py b/cmd2/parsing.py index 4e690b0b..cef0b088 100755 --- a/cmd2/parsing.py +++ b/cmd2/parsing.py @@ -13,9 +13,10 @@ from . import utils def shlex_split(str_to_split: str) -> List[str]: - """A wrapper around shlex.split() that uses cmd2's preferred arguments. + """ + A wrapper around shlex.split() that uses cmd2's preferred arguments. + This allows other classes to easily call split() the same way StatementParser does. - This allows other classes to easily call split() the same way StatementParser does :param str_to_split: the string being split :return: A list of tokens """ @@ -26,8 +27,8 @@ def shlex_split(str_to_split: str) -> List[str]: class MacroArg: """ Information used to replace or unescape arguments in a macro value when the macro is resolved - Normal argument syntax : {5} - Escaped argument syntax: {{5}} + Normal argument syntax: {5} + Escaped argument syntax: {{5}} """ # The starting index of this argument in the macro value start_index = attr.ib(validator=attr.validators.instance_of(int)) |