view move-if-change @ 55228:53c5c7a2f4a8

(outline-next-preface, outline-show-heading): Don't leave unhidden blank line before heading. (outline-end-of-subtree): Include last newline into subtree. (hide-entry): Leave point at beginning of heading instead of end. (outline-up-heading): Push mark for the first call of successive command calls.
author Juri Linkov <juri@jurta.org>
date Thu, 29 Apr 2004 15:34:21 +0000
parents 354e0c45cedf
children 14a97ab281d5
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