[Syncropated-commits] r151 - trunk/src
zimmerle at garage.maemo.org
zimmerle at garage.maemo.org
Mon Jan 29 18:29:21 EET 2007
Author: zimmerle
Date: 2007-01-29 18:29:20 +0200 (Mon, 29 Jan 2007)
New Revision: 151
Added:
trunk/src/syncropated
Log:
Syncropated main
Added: trunk/src/syncropated
===================================================================
--- trunk/src/syncropated 2007-01-27 21:10:39 UTC (rev 150)
+++ trunk/src/syncropated 2007-01-29 16:29:20 UTC (rev 151)
@@ -0,0 +1,69 @@
+#!env python
+
+# syncropated
+#
+# Copyright (c) 2006 INdT (Instituto Nokia de Technologia)
+#
+# Author: Felipe Zimmerle <felipe at zimmerle.org>
+# Kenneth Rohde Christiansen <kenneth.christiansen at gmail.com>
+#
+# This program is free software; you can redistribute it and/or
+# modify it under the terms of the GNU General Public License as
+# published by the Free Software Foundation; either version 2 of the
+# License, or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307
+# USA
+
+
+from syncropated.Logger import Logger
+from syncropated.Syncropated import Syncropated
+import sys
+
+
+def main():
+ """
+ Start logging system and call syncropated main.
+
+ """
+
+ log = Logger()
+ log.info('Syncropated :: Starting syncropated...')
+ log.info('Syncropated :: Start parameters:')
+
+ dryrun = False
+ plugins = True
+
+ for i in sys.argv:
+ log.info(' * ' + str(i))
+ if i == '-debug':
+ log.debug('Syncropated :: Logging mode now is DEBUG')
+ log.setLevel('debug')
+ if i == '-warning':
+ log.debug('Syncropated :: Logging mode now is WARNING')
+ log.setLevel('warning')
+ if i == '-info':
+ log.debug('Syncropated :: Logging mode now is INFO')
+ log.setLevel('info')
+ if i == '-dryrun':
+ log.info('Syncropated :: Dry run mode activeded, adding a fake device.')
+ dryrun=True
+ if i == '-noplugins':
+ log.info('Syncropated :: Disableing the plugins...')
+ plugins = False
+
+ syncropated = Syncropated(dryrun, plugins)
+ syncropated.start()
+
+
+if __name__ == "__main__":
+ main()
+
+
Property changes on: trunk/src/syncropated
___________________________________________________________________
Name: svn:executable
+ *
More information about the Syncropated-commits
mailing list