diff options
author | Igor Pashev <pashev.igor@gmail.com> | 2013-04-14 18:34:38 +0000 |
---|---|---|
committer | Igor Pashev <pashev.igor@gmail.com> | 2013-04-14 18:34:38 +0000 |
commit | 0ca6674b9e3a31219a00ed46acd4d9421ae1c723 (patch) | |
tree | d03da8dcabca5343bba9daffc6e5c5bf882c9473 /install | |
parent | 1e59b39800eefe750aa86c4e5aa354cad4aa7e52 (diff) | |
download | live-0ca6674b9e3a31219a00ed46acd4d9421ae1c723.tar.gz |
Pretty print mirrors
Diffstat (limited to 'install')
-rwxr-xr-x | install | 7 |
1 files changed, 6 insertions, 1 deletions
@@ -516,7 +516,12 @@ def valid_mirror(mirror): def configure_mirror(): global mirror - items = map(lambda x: '{url} ({info})'.format(url=x[0], info=x[1]), mirrors) + global mirrors + maxlen = 0 + for m in mirrors: + if len(m[0]) > maxlen: + maxlen = len(m[0]) + items = map(lambda x: '{url: <{0}} ({info})'.format(maxlen, url=x[0], info=x[1]), mirrors) items.append(('Enter another mirror', None)) mirror = None while not mirror: |