[Date Prev][Date Next] [Thread Prev][Thread Next]
[Thread Index]
[Date Index]
[Author Index]
docs-common/bin move-if-change,1.1,1.2
- From: "Tommy Reynolds" (jtr) <fedora-docs-commits redhat com>
- To: fedora-docs-commits redhat com
- Subject: docs-common/bin move-if-change,1.1,1.2
- Date: Mon, 16 Jan 2006 21:12:22 -0500
Author: jtr
Update of /cvs/docs/docs-common/bin
In directory cvs-int.fedora.redhat.com:/tmp/cvs-serv22901/bin
Modified Files:
move-if-change
Log Message:
Automatically create a backup, similar to "mv -b", if we replace
a file.
Index: move-if-change
===================================================================
RCS file: /cvs/docs/docs-common/bin/move-if-change,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -r1.1 -r1.2
--- move-if-change 17 Jan 2006 02:02:13 -0000 1.1
+++ move-if-change 17 Jan 2006 02:12:00 -0000 1.2
@@ -16,6 +16,9 @@
# along with this program; if not, write to the Free Software
# Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
+# Modified by <Tommy Reynolds MegaCoder com>, for the Fedora Documentation
+# Project, to automatically create a backup of any file we touch.
+
if
test -r $2
then
@@ -25,8 +28,8 @@
echo $2 is unchanged
rm -f $1
else
-mv -f $1 $2
+mv -f -b $1 $2
fi
else
-mv -f $1 $2
+mv -f -b $1 $2
fi
[Date Prev][Date Next] [Thread Prev][Thread Next]
[Thread Index]
[Date Index]
[Author Index]