goa/tools/generate_schema_img.py
changeset 2126 a25859917ccc
parent 1977 606923dff11b
child 4212 ab6573088b4a
--- a/goa/tools/generate_schema_img.py	Thu Jun 18 21:01:55 2009 +0200
+++ b/goa/tools/generate_schema_img.py	Fri Jun 19 14:42:04 2009 +0200
@@ -8,6 +8,7 @@
 import sys
 from os.path import dirname, abspath, join
 from yams import schema2dot
+from cubicweb.web.views.schema import SKIP_TYPES
 
 APPLROOT = abspath(join(dirname(abspath(__file__)), '..'))
 
@@ -22,9 +23,8 @@
 skip_rels = ('owned_by', 'created_by', 'identity', 'is', 'is_instance_of')
 path = join(APPLROOT, 'data', 'schema.png')
 schema2dot.schema2dot(schema, path, #size=size,
-                      skiprels=skip_rels, skipmeta=True)
+                      skiptypes=SKIP_TYPES)
 print 'generated', path
 path = join(APPLROOT, 'data', 'metaschema.png')
-schema2dot.schema2dot(schema, path, #size=size,
-                      skiprels=skip_rels, skipmeta=False)
+schema2dot.schema2dot(schema, path)
 print 'generated', path