X-Git-Url: http://matita.cs.unibo.it/gitweb/?a=blobdiff_plain;f=matita%2Fmatita%2Flib%2Flambda%2Freplace.sh;fp=matita%2Fmatita%2Flib%2Flambda%2Freplace.sh;h=5e281b251228abd56e37bd8cb6125acede3902c4;hb=aa9654656f7d0aeb9345e0b86a9e35f861687580;hp=0000000000000000000000000000000000000000;hpb=637ff9311e16f1d58e03d873f84c354e1cf1e716;p=helm.git diff --git a/matita/matita/lib/lambda/replace.sh b/matita/matita/lib/lambda/replace.sh new file mode 100644 index 000000000..5e281b251 --- /dev/null +++ b/matita/matita/lib/lambda/replace.sh @@ -0,0 +1,10 @@ +#!/bin/sh +for MA in `find -name "*.ma"`; do + echo ${MA}; sed "s!$1!$2!g" ${MA} > ${MA}.new + if diff ${MA} ${MA}.new > /dev/null; + then rm -f ${MA}.new; + else mv -f ${MA} ${MA}.old; mv -f ${MA}.new ${MA}; + fi +done + +unset MA