view move-if-change @ 756:00793f182d30

[xemacs-hg @ 2002-02-22 17:12:26 by michaels] 2002-02-11 Mike Sperber <mike@xemacs.org> * device-x.c: (x_IO_error_handler): (x_init_device): Temporarily keep device in static variable `device_being_initialized' so we can recover gracefully from internal XOpenDevice failure. (XOpenDevice is documented to return NULL on failure, but sometimes calls the IO error handler instead.)
author michaels
date Fri, 22 Feb 2002 17:12:27 +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