Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 07 Aug 2010 02:23:09 -0400
From:      jhell <jhell@dataix.net>
To:        Adam Vande More <amvandemore@gmail.com>
Cc:        ports@freebsd.org, Doug Barton <dougb@freebsd.org>
Subject:   Re: i keep *trying* to move from portupgrade to portmaster
Message-ID:  <4C5CFBCD.8090702@dataix.net>
In-Reply-To: <AANLkTinmwuncNLGqMJRSVk3bnJWjkSRT%2B9atOuEn5haw@mail.gmail.com>
References:  <AANLkTinBJo0M-5fL=ATeY0KXnjA3O-7=TOLMF0X6dzdC@mail.gmail.com> <4C5BC280.1070805@FreeBSD.org> <AANLkTinfXC%2B4J-ZVyUShqKNS3AgpXgwDtnMjVx=iSo9K@mail.gmail.com> <4C5BF352.5050004@dataix.net> <4C5C7DFF.8020400@FreeBSD.org> <AANLkTinmwuncNLGqMJRSVk3bnJWjkSRT%2B9atOuEn5haw@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On 08/06/2010 18:03, Adam Vande More wrote:
> On Fri, Aug 6, 2010 at 4:26 PM, Doug Barton <dougb@freebsd.org> wrote:
> 
>> I need to add an option for this, but it will likely be an "expert"
>> option that you can set in the rc file. The theory is that package
>> creation failure should be a rare thing, and since portmaster has no way
>> to know what packages are really critical to any given system it treats
>> inability to safely recover from an upgrade failure as a critical error.
>> However, having the ability to disable this is an oft-requested feature,
>> I just haven't gotten to it yet.
>>
>> I actually took a look at the code in this area last night with an eye
>> towards creating this option, I'll see if I can get it done for the next
>> release.
>>
> 
> While your in the mood for for taking portmaster suggestions, I think an
> option to backup all currently installed packages would be useful.  I 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.
> 

Just for reference. Doug B. has already touched on this.

#!/bin/sh

trap 'exit 1' 2

_pkg_bld(){
  cd /exports/packages
  for package in `ls /var/db/pkg |sed 's/pkgdb.db//'`; do
    echo "Building package: $package"
    pkg_create -v -b $package >>pkg_bld.log 2>&1
  done
}

_pkg_bld


I never did add a test to see if the package was already there but then
again I used this before extreme situations that the upgrades would span
the whole ports tree.

-- 

 jhell,v




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