[PC-BSD Commits] r8009 - pcbsd/current/src-sh/pbi-manager

svn at pcbsd.org svn at pcbsd.org
Wed Nov 10 07:46:43 PST 2010


Author: kris
Date: 2010-11-10 07:46:42 -0800 (Wed, 10 Nov 2010)
New Revision: 8009

Modified:
   pcbsd/current/src-sh/pbi-manager/pbi-manager
Log:

Improve archiving of old PBIs



Modified: pcbsd/current/src-sh/pbi-manager/pbi-manager
===================================================================
--- pcbsd/current/src-sh/pbi-manager/pbi-manager	2010-11-10 01:47:29 UTC (rev 8008)
+++ pcbsd/current/src-sh/pbi-manager/pbi-manager	2010-11-10 15:46:42 UTC (rev 8009)
@@ -3476,6 +3476,7 @@
 	get_pbi_progversion
         oldVersion=`cat ${PBI_AB_OUTDIR}/${_cd}/pbi-version`
 	if [ "$oldVersion" != "$PBI_PROGVERSION" -a ! -z "`ls ${_od}/*.pbi 2>/dev/null`" ]; then
+		echo "Archiving old PBIs..."
 		oldpbi="`ls ${_od}/*.pbi 2>/dev/null`"
 		archive_old_pbis "$_od" "$oldpbi" "$PBI_AB_ARCHIVENUM"
 	fi
@@ -3881,7 +3882,11 @@
 	# mv the old PBIs into the dir
 	for _oldPBI in $_oldpbifiles
 	do
-  	 	mv "${_od}/${_oldPBI}*" "${_od}/archived/"
+		echo "Moving ${_od}/${_oldPBI} to archive"
+  	 	mv "${_od}/${_oldPBI}" "${_od}/archived/"
+		if [ -e "${_od}/${_oldPBI}.sha256" ] ; then
+  	 		mv "${_od}/${_oldPBI}.sha256" "${_od}/archived/"
+		fi
 	done
 
 	# Prune anything beyond the _keepnum



More information about the Commits mailing list