Date: Wed, 22 Aug 2007 15:43:51 -0500 (CDT) From: "Sean C. Farley" <scf@FreeBSD.org> To: FreeBSD-gnats-submit@FreeBSD.org Cc: ale@FreeBSD.org Subject: ports/115733: [PATCH] ports-mgmt/portconf: support multiple ports per line Message-ID: <200708222043.l7MKhpNI040959@thor.farley.org> Resent-Message-ID: <200708222050.l7MKo2S8024149@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
>Number: 115733 >Category: ports >Synopsis: [PATCH] ports-mgmt/portconf: support multiple ports per line >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-ports-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: change-request >Submitter-Id: current-users >Arrival-Date: Wed Aug 22 20:50:01 GMT 2007 >Closed-Date: >Last-Modified: >Originator: Sean C. Farley >Release: FreeBSD 6.2-STABLE i386 >Organization: >Environment: System: FreeBSD thor.farley.org 6.2-STABLE FreeBSD 6.2-STABLE #0: Sun Jul 29 20:06:46 CDT 2007 >Description: This patch adds support to allow multiple ports on a single line. Instead of having to do: port1: WITH_COOL_FEATURE port2: WITH_COOL_FEATURE you can do this: port1 port2: WITH_COOL_FEATURE Port maintainer (ale@FreeBSD.org) is cc'd. Generated with FreeBSD Port Tools 0.77 >How-To-Repeat: >Fix: --- portconf-1.2.patch begins here --- diff -ruN --exclude=CVS /usr/ports/ports-mgmt/portconf.orig/files/portconf.sh.in /usr/ports/ports-mgmt/portconf/files/portconf.sh.in --- /usr/ports/ports-mgmt/portconf.orig/files/portconf.sh.in 2006-09-06 07:50:31.000000000 -0500 +++ /usr/ports/ports-mgmt/portconf/files/portconf.sh.in 2007-08-22 15:39:11.000000000 -0500 @@ -1,4 +1,4 @@ -#! /bin/sh +#! /bin/sh -f # # Copyright (c) 2006 Florent Thoumie <flz@FreeBSD.org>, # Alex Dupre <ale@FreeBSD.org> @@ -34,8 +34,9 @@ fi _pwd=`pwd` sed '/^#/d;/^[[:space:]]*$/d' "${_conf}" | while read _line; do - _port=${_line%%:*} - if [ "${_pwd%%${_port}}" != "${_pwd}" ]; then - echo ${_line#*:} | sed -E 's/([A-Z0-9_]+)(=([^|]+))?/\1=\3/g;s/ *\| */|/g;s/ /%/g' - fi + for _port in ${_line%%:*}; do + if [ "${_pwd%%${_port}}" != "${_pwd}" ]; then + echo ${_line#*:} | sed -E 's/([A-Z0-9_]+)(=([^|]+))?/\1=\3/g;s/ *\| */|/g;s/ /%/g' + fi + done done --- portconf-1.2.patch ends here --- >Release-Note: >Audit-Trail: >Unformatted:
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200708222043.l7MKhpNI040959>