view move-if-change @ 100936:5c5e6d041634

(decode_coding_utf_8): Check byte_after_cr before breaking the loop. (decode_coding_utf_16, decode_coding_emacs_mule) (decode_coding_iso_2022, decode_coding_sjis, decode_coding_big5) (decode_coding_charset): Likewise.
author Kenichi Handa <handa@m17n.org>
date Wed, 07 Jan 2009 06:49:37 +0000
parents 354e0c45cedf
children 14a97ab281d5
line wrap: on
line source

#!/bin/sh
if
test -r $2
then
if
cmp $1 $2 > /dev/null
then
echo $2 is unchanged
rm -f $1
else
mv -f $1 $2
fi
else
mv -f $1 $2
fi