view move-if-change @ 716:d1ecd411af4c

[xemacs-hg @ 2001-12-26 23:57:55 by youngs] 2001-12-26 John Paul Wallington <jpw@shootybangbang.com> * keydefs.el (global-map): add a defn for C-x 5 1, previously undefined, to run delete-other-frames.
author youngs
date Wed, 26 Dec 2001 23:57:56 +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