From owner-freebsd-ports Tue Aug 24 12:29:35 1999 Delivered-To: freebsd-ports@freebsd.org Received: from rucus.ru.ac.za (rucus.ru.ac.za [146.231.29.2]) by hub.freebsd.org (Postfix) with SMTP id 48C2C15169 for ; Tue, 24 Aug 1999 12:29:25 -0700 (PDT) (envelope-from nbm@rucus.ru.ac.za) Received: (qmail 3064 invoked by uid 1003); 24 Aug 1999 19:30:17 -0000 Date: Tue, 24 Aug 1999 21:30:17 +0200 From: Neil Blakey-Milner To: Will Andrews Cc: ports@FreeBSD.ORG Subject: Re: arb patch to tell who installed port and when Message-ID: <19990824213017.A99983@rucus.ru.ac.za> References: <19990824144734.A73970@rucus.ru.ac.za> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Mailer: Mutt 0.95.6i In-Reply-To: ; from Will Andrews on Tue, Aug 24, 1999 at 12:19:55PM -0400 Sender: owner-freebsd-ports@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.org On Tue 1999-08-24 (12:19), Will Andrews wrote: > On Tue, 24 Aug 1999 14:47:34 +0200, Neil Blakely-Milner stated: > > + if [ -n "${RECORD_USER}" ]; then \ > > + echo ${USER} > ${PKG_DBDIR}/${PKGNAME}/+WHOM; \ > > Where does the value for ${USER} come from? It is not currently defined > anywhere in bsd.port.mk. > > Yes, it's true that in some shell environments, ${USER} is defined. BUT how is > it going to achieve the stated purpose if it only returns the effective > username? Many folks su to root to install ports (that's how they're designed > to be installed by default), and ${USER} will only return 'root', thereby > nullifying the hope of finding out precisely WHO installed the port. hrm, I never thought of that - it doesn't fail if it isn't set though. In most environments I know that use su, su -m is used, which allows things like RCS and similar to give _actual_ user, not "root" all the time. > Also, why not use ${ECHO}? I'm forgetful? > I notice that you would be saving the information in /var/db/pkg/packagename/ > (by default, that is what it would resolve to). I assume you have a script or > something similar to show this information? Or a patch to pkg_info? How else > would this information be made useful? Well, the theory being that ifpeople think it's a good idea, I'd then propose adding an option to pkg*, which isn't too important. For the moment, it's reasonably arbitrary to write a script to work this out, and even manual is useful. Neil -- Neil Blakey-Milner nbm@rucus.ru.ac.za To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-ports" in the body of the message