move the sleep so we correctly handle keyboard interupts

This commit is contained in:
Ronny Pfannschmidt 2011-05-06 22:09:49 +02:00
commit ffe8e00046

View file

@ -141,9 +141,9 @@ def main():
try:
if files_changed(pelican.path, pelican.markup):
pelican.run()
time.sleep(.5) # sleep to avoid cpu load
except KeyboardInterrupt:
break
time.sleep(.5) # sleep to avoid cpu load
else:
pelican.run()
except Exception, e: