view move-if-change @ 899:08513f26c519

[xemacs-hg @ 2002-07-04 13:57:00 by michaels] 2002-07-03 Mike Sperber <mike@xemacs.org> * emacs.c (main_1): We need to call init_ralloc twice for PDUMP, otherwice ralloc won't do anything for us.
author michaels
date Thu, 04 Jul 2002 13:57:03 +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