minstall: Always remove destination file before (re-)creating it.
authorMichel Dänzer <michel@tungstengraphics.com>
Mon, 11 Dec 2006 16:36:35 +0000 (17:36 +0100)
committerMichel Dänzer <michel@tungstengraphics.com>
Mon, 11 Dec 2006 16:36:35 +0000 (17:36 +0100)
This avoids issues with overwriting files that are being used.

bin/minstall

index 9795263f9f17a07b29bc3f55a3f68987f648c2d6..210c2758d3700093e8fb52846eb9515ebd0efe9c 100755 (executable)
@@ -65,6 +65,7 @@ if [ $# -ge 2 ] ; then
 
                elif [ -f "$FILE" ] ; then
                        #echo "$FILE" is a regular file
+                       $RM "$DEST/$FILE"
                        cp "$FILE" "$DEST"
                        if [ $MODE ] ; then
                                FILE=`basename "$FILE"`