From 9fad5b9c46eb60e7fd9e34cd2ccdf96fc5059e7a Mon Sep 17 00:00:00 2001 From: hubertf Date: Sun, 22 Aug 1999 01:30:15 +0000 Subject: Collect information from pkgsrc/*/README.html into one long list (README-all.html), and reference this file. --- Makefile | 39 ++++++++++++++++++++++++++++++++++++++- templates/README.category | 4 +++- templates/README.pkg | 4 +++- templates/README.top | 6 ++++-- 4 files changed, 48 insertions(+), 5 deletions(-) diff --git a/Makefile b/Makefile index d3b562f6df0..6b48f7d792a 100644 --- a/Makefile +++ b/Makefile @@ -1,4 +1,4 @@ -# $NetBSD: Makefile,v 1.24 1999/06/06 19:33:17 frueauf Exp $ +# $NetBSD: Makefile,v 1.25 1999/08/22 01:30:15 hubertf Exp $ # FreeBSD Id: Makefile,v 1.35 1997/08/19 07:10:01 fenner Exp # @@ -78,3 +78,40 @@ search: ${.CURDIR}/INDEX @grep ${key} ${.CURDIR}/INDEX | awk -F\| '{ printf("Port:\t%s\nPath:\t%s\nInfo:\t%s\nMaint:\t%s\nIndex:\t%s\nB-deps:\t%s\nR-deps:\t%s\nArch:\t%s\n\n", $$1, $$2, $$4, $$6, $$7, $$8, $$9, $$10); }' .endif + +# +# Generate list of all packages by extracting information from +# the category/README.html pages +# +readme-all: + @mv README-all.html README-all.html.BAK + @${MAKE} README-all.html + @if cmp -s README-all.html README-all.html.BAK ; then \ + mv README-all.html.BAK README-all.html ; \ + else \ + rm -f README-all.html.BAK ; \ + fi + +README-all.html: + @rm -f $@.new + @rm -f $@.newsorted + @echo -n "Processing categories for $@:" +.for category in ${SUBDIR} + @if [ -f ${category}/README.html ]; then \ + echo -n ' ${category}' ; \ + grep '^' ${category}/README.html \ + | sed -e 's|"|"${category}/|' \ + -e 's| | (${category}) |' \ + -e 's|||' \ + >> $@.new ; \ + fi +.endfor + @echo "." + @sort -t '">' +2 <$@.new >$@.newsorted + @cat templates/README.all \ + | ${SED} \ + -e '/%%PKGS%%/r$@.newsorted' \ + -e '/%%PKGS%%/d' \ + > $@ + @rm -f $@.new + @rm -f $@.newsorted diff --git a/templates/README.category b/templates/README.category index f7944b9b325..a0bb1cc4fcb 100644 --- a/templates/README.category +++ b/templates/README.category @@ -1,4 +1,4 @@ - + The NetBSD Packages Collection: %%CATEGORY%% @@ -26,6 +26,8 @@ in this directory:
[ Go to top of packages tree +| + List all packages ] diff --git a/templates/README.pkg b/templates/README.pkg index 2340063343e..fd7932ff9f3 100644 --- a/templates/README.pkg +++ b/templates/README.pkg @@ -1,4 +1,4 @@ - + The NetBSD Packages Collection: %%PORT%% @@ -60,6 +60,8 @@ precompiled binary form for the following machine architectures: Go up one level | Go to top of packages tree +| + List all packages ] diff --git a/templates/README.top b/templates/README.top index c71d9d010ea..d7686a21d8c 100644 --- a/templates/README.top +++ b/templates/README.top @@ -1,4 +1,4 @@ - + The NetBSD Packages Collection @@ -18,7 +18,9 @@ The packages collection is divided into categories of packages. %%DESCR%%

-

Here are the one-line descriptions for each of the categories: +

Here are the one-line descriptions for each of the categories, +a complete list of all packages is also +available:


-- cgit v1.2.3