summaryrefslogtreecommitdiff
path: root/graph.py
diff options
context:
space:
mode:
authorAlexandre Fayolle <alexandre.fayolle@logilab.fr>2011-02-24 18:44:23 +0100
committerAlexandre Fayolle <alexandre.fayolle@logilab.fr>2011-02-24 18:44:23 +0100
commit4484aa1875d2cddb9afea97bd4d7069aec066825 (patch)
treea947a50f7f5d38c13ba55a5bcdbd49cdb7cb7b18 /graph.py
parent8985d88d10cccec9c59930379f9327f0fc2594ce (diff)
downloadlogilab-common-4484aa1875d2cddb9afea97bd4d7069aec066825.tar.gz
[graph] fix command line construction bug
Diffstat (limited to 'graph.py')
-rw-r--r--graph.py11
1 files changed, 5 insertions, 6 deletions
diff --git a/graph.py b/graph.py
index b66f10d..e4d8e8a 100644
--- a/graph.py
+++ b/graph.py
@@ -111,13 +111,12 @@ class DotBackend:
pdot.close()
if target != 'dot':
if mapfile:
- print '%s -Tcmapx -o%s -T%s %s -o%s' % (self.renderer, mapfile,
- target, dot_sourcepath, outputfile)
- subprocess.call('%s -Tcmapx -o%s -T%s %s -o%s' % (self.renderer, mapfile,
- target, dot_sourcepath, outputfile), shell=True)
+ subprocess.call([self.renderer, '-Tcmapx', '-o', mapfile, '-T', target, dot_sourcepath, '-o', outputfile],
+ shell=True)
else:
- subprocess.call('%s -T%s %s -o%s' % (self.renderer, target,
- dot_sourcepath, outputfile), shell=True)
+ subprocess.call([self.renderer, '-T', target,
+ dot_sourcepath, '-o', outputfile],
+ shell=True)
os.unlink(dot_sourcepath)
return outputfile