Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 15 Jan 2007 05:03:52 +0200
From:      Giorgos Keramidas <keramida@ceid.upatras.gr>
To:        Jonathan Horne <freebsd@dfwlp.com>
Cc:        freebsd-questions@freebsd.org
Subject:   Re: going back in time with the ports tree
Message-ID:  <20070115030352.GA1502@kobe.laptop>
In-Reply-To: <200701141648.34071.freebsd@dfwlp.com>
References:  <200701141648.34071.freebsd@dfwlp.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On 2007-01-14 16:48, Jonathan Horne <freebsd@dfwlp.com> wrote:
> im trying to figure out how to go back in time on my ports tree.  im
> sure ive seen instructions on how to do this before, but for the life
> of me, i cant find the doc now.  i would like to get a copy of ports
> from right before php-5.2.0 was committed.
>
> can anyone point me in the right direction?

If you are using CVSup to update your ports tree, you can use the 'date'
option in your supfile, to specify the precise date-and-time that CVSup
will update your /usr/ports tree to.  The format of the 'date' options
for supfiles is described in cvsup(1) like this:

    date=[cc]yy.mm.dd.hh.mm.ss
        This specifies a date that should be used to select the
        revisions that are checked out from the CVS repository.
        The client will receive the revisions that were in effect
        at the specified date and time.

        At present, the date format is inflexible.  All 17 or 19
        characters must be specified, exactly as shown.  For the
        years 2000 and beyond, specify the century cc.  For earlier
        years, specify only the last two digits yy.  Dates and
        times are considered to be GMT.  The default date is `.',
        which means ``as late as possible''.

Specifying a 'date' in your supfile should be as easy as writing a
special ports-supfile, based on one of the existing examples, like
`/usr/share/examples/cvsup/ports-supfile' and adding a proper "*default"
line.  Since ports are not branched, this means that you can replace:

    *default release=cvs tag=.

with something like:

    *default date=2006.11.24.21.19.45

Now the important detail that you must dig out of the CVS repository is
the exact timestamp you are interested in.  This can be done by using
the web interface of the CVS repository.  You can point your favorite
browser to:

    http://cvsweb.freebsd.org/ports/lang/php5/Makefile

and look at the change log for the port's Makefile.  The elinks(1)
browser which I used here, shows:

% Revision 1.106 / (download) - annotate - [select for diffs],
% Mon Nov 6 17:43:10 2006 UTC (2 months, 1 week ago) by ale
% Branch: MAIN
% Changes since 1.105: +3 -3 lines
% Diff to previous 1.105 (colored)
%
% Update to 5.2.0 release.

So your timestamp should be something definitely *before* the time this
update was committed: `2006.11.06.17.43.10'.  Your supfile could then be
written to contain:

    *default release=cvs tag=.
    *default date=2006.11.06.17.43.00

Having said all this, I'm not sure if it's a good idea to roll back the
entire Ports tree.  You will effectivelly "go back in time", with all
the consequences this can have, like for example rolling back all the
security fixes of Ports which have been committed since then :(

Why do you want to go back to a previous PHP version?  Perhaps we can
solve any problems you have with 5.2.0, so you can keep your Ports tree
up to date *and* have the problems fixed :-)

- Giorgos




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