From 0b7f310081c8be786efa756fb0d1306e4b894c9b Mon Sep 17 00:00:00 2001 From: Romain Bignon Date: Wed, 30 Jun 2010 10:15:50 +0200 Subject: [PATCH] add config file and 'optimizations' field to auto-start them at launch --- weboob/frontends/havesex/havesex.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/weboob/frontends/havesex/havesex.py b/weboob/frontends/havesex/havesex.py index 8e83e91c..256d89c4 100644 --- a/weboob/frontends/havesex/havesex.py +++ b/weboob/frontends/havesex/havesex.py @@ -33,6 +33,7 @@ class HaveSex(PromptApplication): VERSION = '1.0' COPYRIGHT = 'Copyright(C) 2010 Romain Bignon' STORAGE_FILENAME = 'dating.storage' + CONFIG = {'optimizations': ''} def main(self, argv): self.load_config() @@ -40,6 +41,8 @@ class HaveSex(PromptApplication): self.weboob.do('init_optimizations') + self.optims('Starting', 'start_optimization', self.config.get('optimizations').split(' ')) + return self.loop() def split_id(self, id):