1
0
mirror of git://projects.qi-hardware.com/wernermisc.git synced 2024-11-15 06:41:53 +02:00

bin/purge: revert KiCad .pro files in which only the timestamp changed

This commit is contained in:
Werner Almesberger 2010-12-18 05:34:32 -03:00
parent 2c4e3ebd96
commit 9a3f873f7d

12
bin/purge Executable file
View File

@ -0,0 +1,12 @@
#!/bin/sh
if [ "$1" ]; then
cd "$1" || exit
fi
git ls-files -m | grep '.pro$' |
while read n; do
if ! [ "`git diff "$n" |
sed '/^--- /d;/^+++ /d;/^[^-+]/d;/^.update=/d'`" ]; then
echo purging "$n" 1>&2
git checkout "$n"
fi
done