# HG changeset patch # User Brian Neal # Date 1370800945 18000 # Node ID 467295d7807f374c511321d01d4f0a1bfb78ccd4 # Parent 766d8da90e48f88e5f89eb5165fb3ed3cf69b4ba Rename utils.group to utils.group_text. diff -r 766d8da90e48 -r 467295d7807f m209/converter.py --- a/m209/converter.py Sat Jun 08 15:03:28 2013 -0500 +++ b/m209/converter.py Sun Jun 09 13:02:25 2013 -0500 @@ -13,7 +13,7 @@ from .data import KEY_WHEEL_DATA from .key_wheel import KeyWheel, KeyWheelError from .drum import Drum -from .utils import group as group_text +from .utils import group_text M209_ALPHABET_LIST = string.ascii_uppercase M209_ALPHABET_SET = set(string.ascii_uppercase) diff -r 766d8da90e48 -r 467295d7807f m209/procedure.py --- a/m209/procedure.py Sat Jun 08 15:03:28 2013 -0500 +++ b/m209/procedure.py Sun Jun 09 13:02:25 2013 -0500 @@ -25,7 +25,7 @@ from . import M209Error from .converter import M209, M209_ALPHABET_SET, M209_ALPHABET_LIST from .key_wheel import KeyWheelError -from .utils import group as group_text +from .utils import group_text class ProcedureError(M209Error): diff -r 766d8da90e48 -r 467295d7807f m209/utils.py --- a/m209/utils.py Sat Jun 08 15:03:28 2013 -0500 +++ b/m209/utils.py Sun Jun 09 13:02:25 2013 -0500 @@ -5,7 +5,7 @@ """This module contains various utility functions.""" -def group(text, n=5): +def group_text(text, n=5): """Groups the given text into n-letter groups separated by spaces.""" return ' '.join(''.join(text[i:i+n]) for i in range(0, len(text), n))