From bb1e7a5e191d1b6ec1eb2256b42a21dd3e1f8a13 Mon Sep 17 00:00:00 2001 From: Josef Karthauser Date: Wed, 19 May 2004 09:18:08 +0000 Subject: [PATCH] Allow the location of the INDEX file to specified to pkg_version. This is particularly convenient on a cluster of machines to prevent having to rebuild the INDEX file on each. Reviewed by: portmgr --- etc/defaults/periodic.conf | 1 + etc/periodic/weekly/400.status-pkg | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/etc/defaults/periodic.conf b/etc/defaults/periodic.conf index 541fe17b01b4..682692de5950 100644 --- a/etc/defaults/periodic.conf +++ b/etc/defaults/periodic.conf @@ -204,6 +204,7 @@ weekly_noid_dirs="/" # Look here # 400.status-pkg weekly_status_pkg_enable="NO" # Find out-of-date pkgs pkg_version=pkg_version # Use this program +pkg_version_index=/usr/ports/INDEX-5 # Use this index file # 999.local weekly_local="/etc/weekly.local" # Local scripts diff --git a/etc/periodic/weekly/400.status-pkg b/etc/periodic/weekly/400.status-pkg index 2fb4aa6dd5ae..785c2fffd756 100755 --- a/etc/periodic/weekly/400.status-pkg +++ b/etc/periodic/weekly/400.status-pkg @@ -16,7 +16,7 @@ case "$weekly_status_pkg_enable" in echo "" echo "Check for out of date packages:" - rc=$(${pkg_version:-pkg_version} -v | + rc=$(${pkg_version:-pkg_version} -v ${pkg_version_index} | sed -n -e 's/^\([^ ]*\) *< */ \1 /p' \ -e '/^[^ ]*-\([^ ]*\) *\* *multiple versions.*[ ,]\1[,)].*/d' \ -e 's/^\([^ ]*\) *\* *multiple versions.*\((.*\)/ \1 needs updating \2/p' \