Commit 9f6f447e authored by Guilhem Saurel's avatar Guilhem Saurel
Browse files

graph: invert arrow

parent e4332154
Pipeline #930 passed with stages
in 46 seconds
......@@ -115,7 +115,7 @@ def graph_svg(request):
for project in models.Project.objects.filter(from_gepetto=True):
print(f'{{I{project.pk} [label="{project}"];}}', file=f)
for dep in models.Dependency.objects.filter(project__from_gepetto=True, library__from_gepetto=True):
print(f'I{dep.project.pk} -> I{dep.library.pk};', file=f)
print(f'I{dep.library.pk} -> I{dep.project.pk};', file=f)
print('}', file=f)
svg = run(['dot', '/tmp/graph', '-Tsvg'], stdout=PIPE).stdout.decode()
return HttpResponse(svg, content_type='image/svg+xml')
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment