[PC-BSD Commits] r7778 - pcbsd/current/src-qt4/pc-metapkgmanager

svn at pcbsd.org svn at pcbsd.org
Tue Oct 12 11:01:11 PDT 2010


Author: kris
Date: 2010-10-12 11:01:11 -0700 (Tue, 12 Oct 2010)
New Revision: 7778

Modified:
   pcbsd/current/src-qt4/pc-metapkgmanager/pc-metapkgmanager
Log:

Fixed a del bug in pc-metapkgmanager and give a count of the packages to be 
added / removed



Modified: pcbsd/current/src-qt4/pc-metapkgmanager/pc-metapkgmanager
===================================================================
--- pcbsd/current/src-qt4/pc-metapkgmanager/pc-metapkgmanager	2010-10-12 14:58:15 UTC (rev 7777)
+++ pcbsd/current/src-qt4/pc-metapkgmanager/pc-metapkgmanager	2010-10-12 18:01:11 UTC (rev 7778)
@@ -60,6 +60,8 @@
 	fi
 
 	echo "Installing Meta-Package: $_apkg"
+	changes=`wc -l ${MPDIR}/${_apkg}/pkg-list | tr -s '\t' ' ' | cut -d ' ' -f 2`
+	echo "Pending package changes: $changes"
 
         # Now query pkg_info to confirm each pkg is installed
         while read pkg
@@ -106,20 +108,25 @@
 	# kPkgs is our list of packages which are required by other installed meta-pkgs
 	export kPkgs
 
+	# Echo the status
+	changes=`wc -l ${MPDIR}/${_dpkg}/pkg-list | tr -s '\t' ' ' | cut -d ' ' -f 2`
+	echo "Pending package changes: $changes"
+
 	# Lets remove the pkgs from this meta-pkg
 	while read rmPkg
 	do
+
 		# Make sure this pkg is installed
 		pkg_info $rmPkg >/dev/null 2>/dev/null
-		if [ "$?" != "0" ] ; then continue ; fi
+		if [ "$?" != "0" ] ; then echo "Already uninstalled: ${rmPkg}" ; continue; fi
 
 		# confirm this package isn't required by any others
-		pkg_info -R ${rmPkg} | grep "Required by:" >/dev/null 2>/dev/null
-		if [ "$?" = "0" ] ; then continue; fi
+		pkg_info -R ${rmPkg} 2>/dev/null | grep "Required by:" >/dev/null 2>/dev/null
+		if [ "$?" = "0" ] ; then echo "Skipping Required: ${rmPkg}" ; continue; fi
 
 		# Check that this isnt an apart of another meta-pkg installed list
 		echo "$kPkgs" | grep "${rmPkg}:" >/dev/null 2>/dev/null
-		if [ "$?" = "0" ] ; then continue; fi
+		if [ "$?" = "0" ] ; then echo "Skipping Required: ${rmPkg}" ; continue; fi
 
 		echo "Removing ${rmPkg}"
 		pkg_delete ${rmPkg} >/dev/null 2>/dev/null 



More information about the Commits mailing list