Sort specific category by added date?
m.seaman at infracaninophile.co.uk
Wed Jan 12 03:16:25 PST 2005
Sam Lawrance wrote:
> Scott I. Remick wrote:
>> Is there a way (web-based or command-line) to get a list of all the
>> ports in
>> a specific category sorted by their added (not modified/updated) date?
>> For example: I want a list of all the games, sorted by those added most
>> recently first.
>> I can't seem to come up with a trick, but then again, I'm not all that
>> skilled (but still learning!)...
> I was going to suggest looking at the "Date created" which is at the top
> of just about every port Makefile, but there are spelling errors and the
> format varies a little.
> Something like the following might help. It extracts the date that the
> first revision of the Makefile was added. You'll need a copy of the
> ports tree with which you can use 'cvs'. Run it inside a category
> cd /usr/ports/games
> for i in *; do
> echo -n `cvs log -r1.1 $i/Makefile | grep "date:" | cut -c 7-25`;
> echo " $i";
> done | sort
> Needs a bit of tweaking, but you get the idea. The output for 'games' is
> at http://sam.stral.net/freebsd/games-added-date.txt
Or you could look at the Makefile in /usr/ports/games -- specifically
the output of 'cvs annotate':
The 'SUBDIR += portname' lines get basically added when the port is
first committed, so correlating the Makefile version numbers with the
date that version was created will give you a pretty good answer. It's
not perfect -- for instance if the port was renamed it will give you the
date that happened -- but it's probably a lot quicker than an exhaustive
search through the whole CVS history for the category.
Dr Matthew J Seaman MA, D.Phil. 8 Dane Court Manor
PGP: http://www.infracaninophile.co.uk/pgpkey Tilmanstone
Tel: +44 1304 617253 Kent, CT14 0JL UK
-------------- next part --------------
A non-text attachment was scrubbed...
Size: 372 bytes
Desc: OpenPGP digital signature
Url : http://lists.freebsd.org/pipermail/freebsd-ports/attachments/20050112/587faa9f/signature.bin
More information about the freebsd-ports