2

On debianized linux distros there is dpkg --get-selections, dpkg --set-selections, dpkg -C to respectively list installed packages, select a list of packages for installations, and list packages that are in a partially installed or broken state. I am wondering if something like this exists for FreeBSD (ports, not packages). I can get the list from pkg_info, but is there a simple way to apply it without cut, for port in list, cd, make install?

2
  • When you ask this kind of questions, you should describe what the commands you're used to do (like I've done). Otherwise only people who know both systems have a chance to answer. This way someone who only knows FreeBSD has a chance. Commented Apr 9, 2011 at 15:45
  • Sorry Gilles. I haven't probed too deeply into this one(still a FreeBSD n00b, although I do have gnome/flash on native firefox/general multimedia working). Commented Apr 11, 2011 at 17:33

2 Answers 2

2

/usr/ports/ports-mgmt/portmaster man page has example how to do bulk port re-install.

1
  • Thanks. I was using portsnap/portupgrade/portaudit. I hadn't looked into portmaster. The relevant example/switch was --list-origins. Commented Apr 11, 2011 at 17:34
0

If you want to stick with portupgrade, "portupgrade --all" will upgrade all ports that have newer versions available. The "--force" flag can be used to force a re-install or downgrade of a specified port if you know it's broken.

You can get a list of the current versions of your installed ports and whether newer versions are available in your ports tree with "portversion --fullname --verbose".

I don't know of a tool that automatically detects partially installed ports.

1
  • Thanks for the effort. I was looking for a batch install type of thing for installing all currently installed packages on another clean box. AlexD had what I was looking for covered. Commented Jun 21, 2011 at 20:00

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .