From owner-freebsd-ports@FreeBSD.ORG Sat Aug 7 00:46:10 2010 Return-Path: Delivered-To: ports@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 0E9791065676; Sat, 7 Aug 2010 00:46:10 +0000 (UTC) (envelope-from amvandemore@gmail.com) Received: from mail-qw0-f54.google.com (mail-qw0-f54.google.com [209.85.216.54]) by mx1.freebsd.org (Postfix) with ESMTP id 9710E8FC1A; Sat, 7 Aug 2010 00:46:09 +0000 (UTC) Received: by qwg5 with SMTP id 5so4174400qwg.13 for ; Fri, 06 Aug 2010 17:46:08 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:received:received:in-reply-to :references:date:message-id:subject:from:to:cc:content-type; bh=BVY1+JKrBNUk0X/zZJCEpV4Kok4gFdUMQ5P1IlNnq18=; b=Y1+/V3zlCpwRVBjpBnrHYIGexMhSbvAiGMZhFVQWmDnhbPtVIvy+uGXaJKAYmeGV0F YHD1hsmsbji8v1NbcHi/hd/u+cCVDbz8R7MESVGnm2cSvCu1xgrRxLbhxrYrySo55nTC MTV4Vx70mYdduqIKUupAu5IQWPxjRX2M2bnHE= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; b=UMb+HB7pd+s/DUYBdWbJiNe5dj8624ClGBc1TiFBqE8pN6mcSanKrpVczF2gRP7EhY BuSx1Cu8QsxbA0kM/RWb76AxL/6kQ/N9EPxFccys/S37sjjq3DZ6JCha/dzgXfUXItGF hpjwwdmo4lOub9cay1P4bD1gNqqW2swQHUXQQ= MIME-Version: 1.0 Received: by 10.229.215.213 with SMTP id hf21mr4972269qcb.141.1281141968739; Fri, 06 Aug 2010 17:46:08 -0700 (PDT) Received: by 10.229.236.6 with HTTP; Fri, 6 Aug 2010 17:46:08 -0700 (PDT) In-Reply-To: <4C5C88AE.4070500@FreeBSD.org> References: <4C5BC280.1070805@FreeBSD.org> <4C5BF352.5050004@dataix.net> <4C5C7DFF.8020400@FreeBSD.org> <4C5C88AE.4070500@FreeBSD.org> Date: Fri, 6 Aug 2010 19:46:08 -0500 Message-ID: From: Adam Vande More To: Doug Barton Content-Type: text/plain; charset=ISO-8859-1 X-Content-Filtered-By: Mailman/MimeDel 2.1.5 Cc: ports@freebsd.org Subject: Re: i keep *trying* to move from portupgrade to portmaster X-BeenThere: freebsd-ports@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Porting software to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 07 Aug 2010 00:46:10 -0000 On Fri, Aug 6, 2010 at 5:11 PM, Doug Barton wrote: > On 08/06/2010 15:03, Adam Vande More wrote: > > for pkg in /var/db/pkg/* ; do > pkg_create -b $pkg > done > Yes, that is basically what I'm talking about, my script is a little fancier now, prompts for directory with a default if you just want to use a standard location. Also can create directory or clean out an existing one. > > have a python script that does this for me, but it would be easy enough > > to use sh as well. I do this because there have been too many times > > something has broken during a port upgrade run and I need to revert > > immediately and fix later. I realize the backup package feature sort of > > does the same thing, but reconciling the pre- and post- updates is a > > tough thing for me. Having a user defined directory all currently > > installed ports can be put in is much easier to work with IMO. I know of > > other people doing similar things because I shared my script on > > questions- and got a few responses awhile ago. > > It sounds like you want to add the option(s) for "create and keep a > backup package of an installed port" and/or "create a package of the new > port" either to your command line, wrapper script, or a portmaster rc > file. You could use the command line above to create an up to date > repository of your currently installed packages, and the 2 options above > would both make sure you can back out an update and keep your local > package repo up to date automatically. > Yeah, I can and do this via a wrapper, it's certainly works well enough. Maybe some triggers users could set to run pre- and post- postmaster runs? But as you you say, easy enough to do with a wrapper. I don't think pkg_create preserves the config files user edited, which > is the precious stuff, but it preserves a lot of useless stuff. > The following python script by Cyrille Szymanski may be more useful: > http://www.lpthe.jussieu.fr/~talon/pkg_save.py > It keeps the config files and the shared libraries. Yes that's a great script for managing individual packages. Mine is much simpler and there is no need for backing up shared libs since your dealing with a package "snapshot". I also backup /usr/local/etc separately which is where all the package config files I care about live. Also -- Adam Vande More