# HG changeset patch # User Marcin Kuzminski # Date 1361410777 -3600 # Node ID 4b84f435594bc369c4201decc800d18f4fda644d # Parent fe2bb88bf7ac7d117b090f9d1814b5aca7332215 fixed cleanup command diff -r fe2bb88bf7ac -r 4b84f435594b rhodecode/lib/paster_commands/cleanup.py --- a/rhodecode/lib/paster_commands/cleanup.py Thu Feb 21 02:31:21 2013 +0100 +++ b/rhodecode/lib/paster_commands/cleanup.py Thu Feb 21 02:39:37 2013 +0100 @@ -125,23 +125,26 @@ if remove: for path, date_ in to_remove: print >> sys.stdout, 'removing repository %s' % path - shutil.rmtree(path)) + shutil.rmtree(path) else: print 'nothing done exiting...' sys.exit(0) def update_parser(self): - self.parser.add_option('--older-than', - action='store', - dest='older_than', - help=( - "only remove repos that have been removed " - "at least given time ago " - "ex. --older-than=30d deletes repositores " - "removed more than 30days ago. Possible options " - "d[ays]/h[ours]/m[inutes]/s[seconds]. OPTIONAL"), - ) - self.parser.add_option('--dont-ask', - action='store_true', - dest='dont_ask', - help=("Don't ask to remove repos")) + self.parser.add_option( + '--older-than', + action='store', + dest='older_than', + help=("only remove repos that have been removed " + "at least given time ago " + "ex. --older-than=30d deletes repositores " + "removed more than 30days ago. Possible options " + "d[ays]/h[ours]/m[inutes]/s[seconds]. OPTIONAL") + ) + + self.parser.add_option( + '--dont-ask', + action="store_true", + dest="dont_ask", + help="Don't ask to remove repos" + )