view move-if-change @ 4299:f4c3ffe60a4f

[xemacs-hg @ 2007-12-01 14:24:46 by aidan] Switch away from ISO 2022 for the ISO-8859 character sets.
author aidan
date Sat, 01 Dec 2007 14:24:52 +0000
parents 376386a54a3c
children
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