Date: Sun, 2 Dec 2012 11:26:16 +0200 From: Ion-Mihai Tetcu <itetcu@FreeBSD.org> To: Matthew Seaman <m.seaman@infracaninophile.co.uk> Cc: freebsd-ports@freebsd.org Subject: Re: web FreeBSD Ports Search is out of sync Message-ID: <20121202112616.65a580d5@it.tim.tetcu.info> In-Reply-To: <50BB162F.1040309@infracaninophile.co.uk> References: <50BA347D.9080301@quip.cz> <CAF6rxgkhbOLN3ZZhxRZgYtQWF4yeHjiPS68YryKE-vAqitAvFg@mail.gmail.com> <CAN6yY1tqH857Ju2C8ADVPYG9VzhJYmY3Rya9fAvP=pcbVvvuRA@mail.gmail.com> <CA%2B7WWSeT-FTD=YBvbBcjhWWSWUbcMjfUiwtwaXYVPW=yZruo8w@mail.gmail.com> <20121202102250.50553fbc@it.tim.tetcu.info> <50BB162F.1040309@infracaninophile.co.uk>
next in thread | previous in thread | raw e-mail | index | archive | help
On Sun, 02 Dec 2012 08:49:51 +0000 Matthew Seaman <m.seaman@infracaninophile.co.uk> wrote: > On 02/12/2012 08:22, Ion-Mihai Tetcu wrote: > > You might want to try ports-mgmt/p5-FreeBSD-Portindex > > cache-init(1) will take that half an hour, but after that updating > > the INDEX will take a minute or so (depending on what has changed > > in the PT since your last update). Also you'll have an INDEX that > > reflects your local settings (make.conf, OPTIONS). > > Thanks for the recommendation. Always glad to hear that people a > making use of my code. I'm a fan since I was running it on an k6-II :) > > > # m /root/bin/ports_upd.sh > > #!/bin/sh > > > > DATE=`date "+%Y-%m-%d_%H_%M_%S"` > > LOG_DIR=/var/log/ports > > PSNAP_LOG=${LOG_DIR}/psnap.${DATE} > > > > /usr/sbin/portsnap fetch > > /usr/sbin/portsnap update | tee ${PSNAP_LOG} > > /usr/local/bin/cache-update -f plain,options -i ${PSNAP_LOG} | tee > > ${PSNAP_LOG}.cu > > Actually, nowadays you don't need to save the output of portsnap or > cvsup or whatever, and use '-f plain,options' to parse that. The > changes in version 2.8 mean portindex can detect when the timestamp > on any ports Makefile or pkg-descr file or the options saved > in /var/db/ports has changed, and determine what ports it needs to > recheck from that, so it's completely independent of the mechanism[*] > used to update the tree. This doesn't really take significantly more > or less time than the old 'parse the logfile' approach -- all those > make invocations are the slow step. > > Just run 'cache-update' without arguments. This depends on the speed of your disks and on many of my mahcines, that is the limitting factor. On my home raidz that timestamp checking made everyting a few times longer. Besides, I like to have things logged. > > grep -qv 'Nothing to do' ${PSNAP_LOG}.cu && \ > > /usr/local/bin/portindex -v -o ${PORTSDIR}/INDEX-9 > > > > portmaster -L --no-index-fetch --index | egrep -B1 '(ew|ort) > > version|Aborting|installed|dependencies|IGNORE|marked|Reason:|MOVED' > > | grep -v '^--' > > Cheers, > > Matthew > > [*] And less error prone. As long as you use portsnap (ie. local port changes are discarded) and you run cache-update each time, I don't see the difference. -- IOnut - Un^d^dregistered ;) FreeBSD "user" "Intellectual Property" is nowhere near as valuable as "Intellect" FreeBSD committer -> itetcu@FreeBSD.org, PGP Key ID F0808380
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20121202112616.65a580d5>