mirror of
https://github.com/a-b-street/abstreet.git
synced 2024-12-25 15:33:44 +03:00
tool to compare screencaps
This commit is contained in:
parent
09a3aed407
commit
66ef25c8aa
14
editor/compare_screencaps.py
Executable file
14
editor/compare_screencaps.py
Executable file
@ -0,0 +1,14 @@
|
||||
#!/usr/bin/python2
|
||||
|
||||
import os
|
||||
import subprocess
|
||||
import sys
|
||||
|
||||
def run():
|
||||
|
||||
print sorted(os.listdir(sys.argv[1]))
|
||||
print sorted(os.listdir(sys.argv[2]))
|
||||
|
||||
|
||||
if __name__ == '__main__':
|
||||
run()
|
17
editor/compare_screencaps.sh
Executable file
17
editor/compare_screencaps.sh
Executable file
@ -0,0 +1,17 @@
|
||||
#!/bin/bash
|
||||
|
||||
before=$1;
|
||||
after=$2;
|
||||
|
||||
rm -rf diff
|
||||
mkdir diff
|
||||
|
||||
for file in `ls $before | grep -v full.png`; do
|
||||
diff $before/$file $after/$file;
|
||||
if [ $? -eq 1 ]; then
|
||||
compare $before/$file $after/$file diff/$file;
|
||||
if [ "$3" == "-i" ]; then
|
||||
ristretto diff/$file $before/$file $after/$file;
|
||||
fi
|
||||
fi
|
||||
done
|
@ -1,7 +1,6 @@
|
||||
#!/usr/bin/python2
|
||||
|
||||
import os
|
||||
import subprocess
|
||||
import sys
|
||||
|
||||
def run():
|
||||
|
Loading…
Reference in New Issue
Block a user