Skip site navigation (1)Skip section navigation (2)
Date:      Sun, 9 Mar 1997 01:34:08 -0800 (PST)
From:      "Jordan K. Hubbard" <jkh@time.cdrom.com>
To:        asami@freebsd.org
Cc:        ports@freebsd.org
Subject:   What do you think of this little hack to /usr/ports/Makefile ?
Message-ID:  <199703090934.BAA12771@time.cdrom.com>

next in thread | raw e-mail | index | archive | help
Index: Makefile
===================================================================
RCS file: /home/ncvs/ports/Makefile,v
retrieving revision 1.29
diff -u -r1.29 Makefile
--- Makefile	1997/03/06 05:52:26	1.29
+++ Makefile	1997/03/09 09:32:46
@@ -48,3 +48,13 @@
 
 print-index:	${.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\n\n", $$1, $$2, $$4, $$6, $$7, $$8, $$9); }' < ${.CURDIR}/INDEX
+
+PAGER?=	more
+
+search:	${.CURDIR}/INDEX
+.if !defined(key)
+	@echo "The search target requires a keyword parameter,"
+	@echo "e.g.: \"make search key=somekeyword\""
+.else
+	@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\n\n", $$1, $$2, $$4, $$6, $$7, $$8, $$9); }' | ${PAGER}
+.endif



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199703090934.BAA12771>