diff options
author | Mattias Andrée <maandree@operamail.com> | 2012-09-01 06:14:46 +0200 |
---|---|---|
committer | Mattias Andrée <maandree@operamail.com> | 2012-09-01 06:14:46 +0200 |
commit | 1b78d94ef445623b58dcab760bbdc7f110761c2e (patch) | |
tree | 7f806d828e45f5cb066f11f62dada0472a066736 | |
parent | db2d8f41fa9436e0a31ed89600664af5bf34672f (diff) | |
download | ponysay-1b78d94ef445623b58dcab760bbdc7f110761c2e.tar.gz ponysay-1b78d94ef445623b58dcab760bbdc7f110761c2e.tar.bz2 ponysay-1b78d94ef445623b58dcab760bbdc7f110761c2e.zip |
m ponyquotes build + setup args typo fix
-rwxr-xr-x | setup.py | 13 |
1 files changed, 7 insertions, 6 deletions
@@ -102,7 +102,7 @@ class Setup(): opts.add_argumentless(help = 'Only install explicitly included shell completions', - alternatives = ['--without-shell' + '--without-shell-completion']) + alternatives = ['--without-shell', '--without-shell-completion']) opts.add_argumented (help = 'Set share/ directory used for shell completions\nDefault = $SHAREDIR', alternatives = ['--with-shell', '--with-shell-completion'], arg='SHAREDIR') @@ -459,11 +459,12 @@ class Setup(): ponies = [line for line in ponymap.read().decode('utf-8', 'replace').split('\n')] for _ponies in ponies: for pony in _ponies.split('+'): - print('Generating quote files for \033[34m' + pony + '\033[39m') - for file in os.listdir('ponyquotes'): - if file.startswith(pony + '.'): - if os.path.isfile('ponyquotes/' + file): - shutil.copy('ponyquotes/' + file, 'quotes/' + _ponies + file[file.find('.'):]) + if len(pony) > 0: + print('Generating quote files for \033[34m' + pony + '\033[39m') + for file in os.listdir('ponyquotes'): + if file.startswith(pony + '.'): + if os.path.isfile('ponyquotes/' + file): + shutil.copy('ponyquotes/' + file, 'quotes/' + _ponies + file[file.find('.'):]) finally: if ponymap is not None: ponymap.close() |