#!/usr/local/bin/bash portupgrade="/usr/local/sbin/portupgrade" pkg_ver="/usr/sbin/pkg_version" LIST=`${pkg_ver} -v | grep 'need' | awk '{print $1}'` for pkg_name in ${LIST} do ${portupgrade} -f ${pkg_name} done
ADVERTISEMENT