projects
/
tools
/
apitrace.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
0798473
)
snapdiff: Compare .bmp images too.
author
José Fonseca
<jose.r.fonseca@gmail.com>
Tue, 13 Dec 2011 15:53:49 +0000
(15:53 +0000)
committer
José Fonseca
<jose.r.fonseca@gmail.com>
Tue, 13 Dec 2011 15:54:03 +0000
(15:54 +0000)
Quite common too.
scripts/snapdiff.py
patch
|
blob
|
history
diff --git
a/scripts/snapdiff.py
b/scripts/snapdiff.py
index
b7bad72
..
ddc2bf7
100755
(executable)
--- a/
scripts/snapdiff.py
+++ b/
scripts/snapdiff.py
@@
-121,10
+121,11
@@
def surface(html, image):
def is_image(path):
- return \
- path.endswith('.png') \
- and not path.endswith('.diff.png') \
- and not path.endswith('.thumb.png')
+ name = os.path.basename(path)
+ name, ext1 = os.path.splitext(name)
+ name, ext2 = os.path.splitext(name)
+ print name, ext1, ext2
+ return ext1 in ('.png', '.bmp') and ext2 not in ('.diff', '.thumb')
def find_images(prefix):