view move-if-change @ 2216:352d35ff1c82

[xemacs-hg @ 2004-08-13 20:55:31 by adrian] A small patch to config.guess to detect the PlayStation2 <16667.42748.6448.605562@jin.myrkraverk.com>
author adrian
date Fri, 13 Aug 2004 20:55:31 +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