ports INDEX - how often

ports INDEX - how often

Post by Joel Hatto » Wed, 13 Oct 2004 16:14:52

Just when I thought I'd exhausted all the questions I could come up with
for ports... How often should I run 'make index' in /usr/ports? Each
time I run 'make update'?


ports INDEX - how often

Post by conrad » Wed, 13 Oct 2004 20:39:30

In article <ckg09c$c5m$ XXXX@XXXXX.COM >,


Many of us do this as a nightly cron job, like so (note that "portsdb
-Uu" is a better way of doing "make index", as it updates *all* of the
INDEX.* files, the portversion command is to provide a listing of ports that
need upgrading in the cron job's mailed output, and ignore the line wrap):

0 2 * * * cd /usr/ports && make update && portsdb -Uu && portversion -v -O
-L '=' && { make -k readmes >/dev/null; }

Conrad J. Sabatier < XXXX@XXXXX.COM > -- "In Unix veritas"


ports INDEX - how often

Post by Joel Hatto » Thu, 14 Oct 2004 09:25:42

Thanks Conrad for the advice. I continue to be bitten by my inexperience
with this process. In my defence I must note that there appears some
inconsistency in that some things are able to be make-d, but others like
portsdb,pkgdb etc. can't.

I think two things would be helpful:

o the normal handbook could be updated with the correct procedure for
ports maintenance - it still has only the basics of using the cvsup
command and nothing about the makefile or other important commands

o the toplevel ports makefile could include targets for all of the
essential actions; maybe the 'update' should include the essential db
operations, or another eg 'update-all'? As you mention, portsdb -Uu is
better than 'make index' - should this be changed in the makefile?

Failing either of the above, has anyone documented this process already
in a form that is available and has been verified by all or some of you?
Maybe by the time I get through this I'll be ready to have a crack at
documenting it myself ;)

thanks again