portupgrade
Portupgrade (also known as pkgtools) is a set of tools for working with ports and packages. It enhances system tools and adds many new abilities. It is easily and highly configurable, allowing you to create individual, variable environments for any port you like, and to define commands that will be executed before/after port upgrade stages.
pkgtools uses hash databases so access to information about available (in the ports tree) and installed ports and their dependencies is fast.
pkgtools consist of the utils:
pkg_delete(1) and provides additional features.pkg_version(1).and a few other.
Initially pkgtools was written by Akinori MUSHA
It is currently maintained by BryanDrewery
These people have maintained the project over time.
pkgtools.conf. You'll find many interesting examples there.pkgtools.conf and you'll always have service started after an upgrade process:AFTERINSTALL = {
'*' => proc { |origin|
cmd_start_rc(origin)
},
}
INDEX and rebuild portsdb with one command:portsdb -Fu
portinstall(1) and pkg_deinstall(1).portcvsweb(1) easily.portsclean -D will purge old distfiles. portsclean -C will clean all 'work' directories. portsclean -L will clean up unused libraries in /usr/local/lib/compat/pkg. portsclean -P will clean up outdated packages.-b option.portupgrade -a -x ruby -x portupgrade
pkgdu -tr ruby
-c/-C options for portupgrade helps when you plan to update many ports. poruptgrade will run make config for all ports you want upgrade before upgrading process. So you can configure all of them and go to rest while the ports updating.pkg_glob '<2008-07-10' - it shows packages older the data. It can be very useful to update all packages older some date with the command:portupgrade -fa -x '>=2008-07-10'
portsbackup and portsrestore utilites. They will save ports data (/etc/make.conf, /var/db/pkg, /var/db/ports, /usr/local/etc) and restore all ports on another computer by rebuilding them from the ports tree. (The idea belongs to AndrejZverev).Send your wishes, bug reports to http://github.com/pkgtools/pkgtools or bdrewery@FreeBSD.org
From: MatthiasAndree
pkgdb -F offers to unregister one package's metadata without removing its files. pkgdb -F might however compare the package lists of all packages and remove files that are unique to the package to be deinstalled (i. e. not installed by the package that remains). Example: assume package-1.1 with files a, b, c and package-1.1_4 with files a, c, e are installed. In this case, pkgdb -F could offer to remove “b” if package-1.1 is deinstalled.pkgdb -F might count the number of MD5 mismatches of the installed files to figure out which package data is more current or fits the existing installation better, and default to installing metadata with most mismatches.From: Hannes Hauswedell <hannes.hauswedell at gmail.com>
From: RW <list-freebsd-2004 at morbius.sent.com>
pkg_add -f to install packages. pkg_add is supposed to install the missing dependencies itself, but sometimes they are missing in the repository. Because it uses the -f option pkg_add is able to proceed without the missing dependency. Personally, I think it might be cleaner to drop the -f option and allow the pkg_add to fail.From: AndrewPantyukhin
From: AlexanderLeidinger
From: Chris Calvey <chris at securityforensics.co.uk>