Replace .config rather than reconstructing plugins, drivers, and UIs.
[hooke.git] / hooke / plugin / __init__.py
index 3d3efd9b93a48666a8cda0739d55fd199eae5881..d04f3740f3797fae36e731a0d01de3a43d56622f 100644 (file)
@@ -34,15 +34,14 @@ PLUGIN_MODULES = [
     ('convfilt', True),
     ('cut', True),
 #    ('fclamp', True),
-#    ('fit', True),
 #    ('flatfilts-rolf', True),
     ('flatfilt', True),
 #    ('jumpstat', True),
-#    ('macro', True),
 #    ('massanalysis', True),
 #    ('multidistance', True),
 #    ('multifit', True),
 #    ('pcluster', True),
+    ('polymer_fit', True),
 #    ('procplots', True),
 #    ('review', True),
 #    ('showconvoluted', True),
@@ -56,9 +55,11 @@ default.  TODO: autodiscovery
 """
 
 BUILTIN_MODULES = [
+    'command_stack',
     'config',
     'curve',
     'debug',
+    'engine',
     'license',
     'note',
     'playlist',
@@ -124,11 +125,15 @@ def argument_to_setting(section_name, argument):
     """Convert an :class:`~hooke.command.Argument` to a
     `~hooke.conf.Setting`.
 
-    This is a lossy transition, because
+    This is useful if, for example, you want to define arguments with
+    configurable default values.
+
+    Conversion is lossy transition, because
     :class:`~hooke.command.Argument`\s store more information than
     `~hooke.conf.Setting`\s.
     """
     return Setting(section_name, option=argument.name, value=argument.default,
+                   type=argument.type, count=argument.count,
                    help=argument._help)
 
 
@@ -182,9 +187,5 @@ def load_graph(graph, config, include_section):
                      % (item.name, dependency.data.name))
                     enabled[item.name] = False
                     continue
-            try:
-                item.config = dict(config.items(item.setting_section))
-            except configparser.NoSectionError:
-                pass
             items.append(item)
     return items