chiark / gitweb /
Allow plugin variable names to include underscore
authorsmorloc <smorloc@gmail.com>
Tue, 22 Jan 2013 18:07:57 +0000 (13:07 -0500)
committersmorloc <smorloc@gmail.com>
Tue, 22 Jan 2013 18:07:57 +0000 (13:07 -0500)
For instance 'big_cheese'

Cura/util/profile.py

index 36d76c4e8fc5e87f6de80556eb942230ffe4cbff..540dae128063a30bfd2f58f62bf80b1f273f9095 100644 (file)
@@ -586,7 +586,7 @@ def getPluginList():
                                        elif line[0].upper() == 'DEPEND':
                                                pass
                                        elif line[0].upper() == 'PARAM':
-                                               m = re.match('([a-zA-Z][a-zA-Z0-9]*)\(([a-zA-Z_]*)(?::([^\)]*))?\) +(.*)', line[1].strip())
+                                               m = re.match('([a-zA-Z][a-zA-Z0-9_]*)\(([a-zA-Z_]*)(?::([^\)]*))?\) +(.*)', line[1].strip())
                                                if m is not None:
                                                        item['params'].append({'name': m.group(1), 'type': m.group(2), 'default': m.group(3), 'description': m.group(4)})
                                        else: