pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/pkgtools/pkgsurvey pkgsurvey-1.0: Build the package li...



details:   https://anonhg.NetBSD.org/pkgsrc/rev/8edbe9b7c6a2
branches:  trunk
changeset: 651748:8edbe9b7c6a2
user:      joerg <joerg%pkgsrc.org@localhost>
date:      Sun May 10 19:47:03 2015 +0000

description:
pkgsurvey-1.0: Build the package list in a more useful format by
including package name, package location and automatic flag. Send to a
new list to keep the new format separate from the old one.

diffstat:

 pkgtools/pkgsurvey/Makefile           |  4 ++--
 pkgtools/pkgsurvey/files/pkgsurvey.sh |  9 ++++++++-
 2 files changed, 10 insertions(+), 3 deletions(-)

diffs (30 lines):

diff -r d32b9188f393 -r 8edbe9b7c6a2 pkgtools/pkgsurvey/Makefile
--- a/pkgtools/pkgsurvey/Makefile       Sun May 10 19:21:38 2015 +0000
+++ b/pkgtools/pkgsurvey/Makefile       Sun May 10 19:47:03 2015 +0000
@@ -1,7 +1,7 @@
-# $NetBSD: Makefile,v 1.13 2014/03/03 03:30:55 obache Exp $
+# $NetBSD: Makefile,v 1.14 2015/05/10 19:47:03 joerg Exp $
 #
 
-PKGNAME=       pkgsurvey-0.0
+PKGNAME=       pkgsurvey-1.0
 CATEGORIES=    pkgtools
 
 MAINTAINER=    agc%pkgsrc.org@localhost
diff -r d32b9188f393 -r 8edbe9b7c6a2 pkgtools/pkgsurvey/files/pkgsurvey.sh
--- a/pkgtools/pkgsurvey/files/pkgsurvey.sh     Sun May 10 19:21:38 2015 +0000
+++ b/pkgtools/pkgsurvey/files/pkgsurvey.sh     Sun May 10 19:47:03 2015 +0000
@@ -1,5 +1,12 @@
 #! /bin/sh
 
-${PKG_INFO} | sort | mail -s "`hostname` `${UNAME} -s`-`${UNAME} -p`-`${UNAME} -r`" agc-pkgsurvey%pkgsrc.org@localhost
+${PKG_INFO} -e '*' | while read pkg; do
+       path=`${PKG_INFO} -Q PKGPATH "$pkg"`
+       automatic=`${PKG_INFO} -Q automatic "$pkg"`
+       if [ -z "$automatic" ]; then
+               automatic=no
+       fi
+       echo "$path $pkg $automatic"
+done | sort | mail -s "`hostname` `${UNAME} -s`-`${UNAME} -p`-`${UNAME} -r`" pkgsurvey1.0%pkgsrc.org@localhost
 
 exit 0



Home | Main Index | Thread Index | Old Index