Merge lp:~knitzsche/dotdepends/bug-1022674 into lp:dotdepends

Proposed by Kyle Nitzsche
Status: Merged
Merged at revision: 67
Proposed branch: lp:~knitzsche/dotdepends/bug-1022674
Merge into: lp:dotdepends
Diff against target: 39 lines (+13/-2)
2 files modified
debian/changelog (+7/-0)
usr/bin/dotdepends (+6/-2)
To merge this branch: bzr merge lp:~knitzsche/dotdepends/bug-1022674
Reviewer Review Type Date Requested Status
Mike Carifio Approve
Review via email: mp+114022@code.launchpad.net
To post a comment you must log in.
Revision history for this message
Mike Carifio (carifio) wrote :

You're relying on .png being the only graphical output format rather than testing the -d switch directly. If you ever adopt multiple graphics formats, you might have to update this. But let's press ahead.

review: Approve
Revision history for this message
Kyle Nitzsche (knitzsche) wrote :

Mike: good point. Although png is the currently single hardcoded format if -d is used.

Preview Diff

[H/L] Next/Prev Comment, [J/K] Next/Prev File, [N/P] Next/Prev Hunk
1=== modified file 'debian/changelog'
2--- debian/changelog 2012-07-09 17:48:25 +0000
3+++ debian/changelog 2012-07-09 18:21:18 +0000
4@@ -1,3 +1,10 @@
5+dotdepends (0.3.14kyle1) UNRELEASED; urgency=low
6+
7+ * fix recent failures of -d option on dotdepends (disables auto running of
8+ dot to produce pngs in default mode). LP: #1022674
9+
10+ -- Kyle Nitzsche <kyle.nitzsche@canonical.com> Mon, 09 Jul 2012 14:12:10 -0400
11+
12 dotdepends (0.3.14) precise; urgency=low
13
14 * usr/bin/dotdepends: move import of Dotdepends after code needed to set
15
16=== modified file 'usr/bin/dotdepends'
17--- usr/bin/dotdepends 2012-07-09 17:30:46 +0000
18+++ usr/bin/dotdepends 2012-07-09 18:21:18 +0000
19@@ -256,7 +256,9 @@
20 # return process return code iff more specific
21 sys.exit(max(1, p.returncode))
22
23- f1dot = f1.rstrip('.png\n') + ".dot"
24+ f1dot = f1.rstrip('.png\n')
25+ if not f1dot.endswith(".dot"):
26+ f1dot += ".dot"
27 cmd = [
28 path.basename(__file__),
29 '-o', opt.output_dir, '-r',
30@@ -277,7 +279,9 @@
31 print >> sys.stderr, f2[1]
32 exit(1)
33
34- f2dot = f2[0].rstrip('.png\n') + ".dot"
35+ f2dot = f2[0].rstrip('.png\n')
36+ if not f2dot.endswith(".dot"):
37+ f2dot += ".dot"
38 #print "f2dot %s" % f2dot
39 f3 = open(f2dot, 'r').readlines()
40

Subscribers

People subscribed via source and target branches

to all changes: