You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@subversion.apache.org by Karl Fogel <kf...@newton.ch.collab.net> on 2003/02/20 18:45:08 UTC

Re: tracking path ancestery

ender <en...@objectrealms.net> writes:
> i'm trying to write a cross-copy annotation of a file, using the python 
> bindings.  i've dug around in the source, and docs, and don't see a good way 
> to do it without an exhaustive search. is there a better solution, any tips 
> appreciated.

svn_log won't cross the copy boundaries for you?

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: tracking path ancestery

Posted by ender <en...@objectrealms.net>.
On Thursday 20 February 2003 12:00 pm, cmpilato@collab.net wrote:
> ender <en...@objectrealms.net> writes:
> > i want to produce a line by line annotation/blame showing revision
> > number and author for changes of a non-binary file node's
> > contents. perhaps a picture is more clear.
> >
> > http://objectrealms.net/projects/svn_browser/pics/Annotation.png
>
> Wow.  Sure looks pretty.

thanks, it only gets better ;-)  i can't take any of the credits for the good 
looks.. the css wizards at plone.org handled that.

>
> > to do that i need to get a hold of node's path across all of its
> > revisions_changed including copies to get ahold of its
> > contents. currently doing that seems to be problematic, mainly due
> > to expense of iterating through n*m upper bound of copy checks
> > combinations of n, revision changes to the node, and m representing
> > the number of hierarchical containers for the node (though in
> > actuality the number is much less). i was hoping that there was
> > another mechanism that svn provided for reconstructing a given
> > node's path across revisions.
>
> I am planning to make svn_fs_revisions_changed() go way, and replace
> it with svn_fs_node_revisions() which will do the same thing that
> revisions_changed() does, but will optionally return a path for each
> revision in which the node changed.

that would be perfect! i guess this will be using the new repos uuids..

in case its of interest to anyone i'm attaching the code i just finished which 
returns a map of rev numbers to repo paths given a node (the pic above was a 
setup, no copies involved). its not very pretty nor perhaps useful ;-), other 
than looking at the algorithm..  it works ok for the minimal test cases i 
gave it.

thanks guys,

-e

Re: tracking path ancestery

Posted by cm...@collab.net.
ender <en...@objectrealms.net> writes:

> i want to produce a line by line annotation/blame showing revision
> number and author for changes of a non-binary file node's
> contents. perhaps a picture is more clear.
> 
> http://objectrealms.net/projects/svn_browser/pics/Annotation.png

Wow.  Sure looks pretty.

> to do that i need to get a hold of node's path across all of its
> revisions_changed including copies to get ahold of its
> contents. currently doing that seems to be problematic, mainly due
> to expense of iterating through n*m upper bound of copy checks
> combinations of n, revision changes to the node, and m representing
> the number of hierarchical containers for the node (though in
> actuality the number is much less). i was hoping that there was
> another mechanism that svn provided for reconstructing a given
> node's path across revisions.

I am planning to make svn_fs_revisions_changed() go way, and replace
it with svn_fs_node_revisions() which will do the same thing that
revisions_changed() does, but will optionally return a path for each
revision in which the node changed.


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: tracking path ancestery

Posted by ender <en...@objectrealms.net>.
On Thursday 20 February 2003 11:35 am, cmpilato@collab.net wrote:
> ender <en...@objectrealms.net> writes:
> > On Thursday 20 February 2003 10:45 am, Karl Fogel wrote:
> > > ender <en...@objectrealms.net> writes:
> > > > i'm trying to write a cross-copy annotation of a file, using the
> > > > python bindings.  i've dug around in the source, and docs, and don't
> > > > see a good way to do it without an exhaustive search. is there a
> > > > better solution, any tips appreciated.
> > >
> > > svn_log won't cross the copy boundaries for you?
> >
> > not afaics... but svn log doesn't need to cross copy boundaries, it can
> > just get a change revision set (including copy revs) and pick off log
> > /author from the revision props, it doesn't need to get the path. i'd
> > love to be told otherwise ;-)
>
> So...  svn_fs_revisions_changed isn't doing the job for you?  (Sorry,
> I still don't really understand what you're trying to accomplish.)

i want to produce a line by line annotation/blame showing revision number and 
author for changes of a non-binary file node's contents. perhaps a picture is 
more clear.

http://objectrealms.net/projects/svn_browser/pics/Annotation.png

to do that i need to get a hold of node's path across all of its 
revisions_changed including copies to get ahold of its contents. currently 
doing that seems to be problematic, mainly due to expense of iterating 
through n*m upper bound of copy checks combinations of n, revision changes to 
the node, and m representing the number of hierarchical containers for the 
node (though in actuality the number is much less). i was hoping that there 
was another mechanism that svn provided for reconstructing a given node's 
path across revisions. 

-e


---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: tracking path ancestery

Posted by cm...@collab.net.
ender <en...@objectrealms.net> writes:

> On Thursday 20 February 2003 10:45 am, Karl Fogel wrote:
> > ender <en...@objectrealms.net> writes:
> > > i'm trying to write a cross-copy annotation of a file, using the python
> > > bindings.  i've dug around in the source, and docs, and don't see a good
> > > way to do it without an exhaustive search. is there a better solution,
> > > any tips appreciated.
> >
> > svn_log won't cross the copy boundaries for you?
> 
> not afaics... but svn log doesn't need to cross copy boundaries, it can just 
> get a change revision set (including copy revs) and pick off log /author from 
> the revision props, it doesn't need to get the path. i'd love to be told 
> otherwise ;-)

So...  svn_fs_revisions_changed isn't doing the job for you?  (Sorry,
I still don't really understand what you're trying to accomplish.)

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org

Re: tracking path ancestery

Posted by ender <en...@objectrealms.net>.
On Thursday 20 February 2003 10:45 am, Karl Fogel wrote:
> ender <en...@objectrealms.net> writes:
> > i'm trying to write a cross-copy annotation of a file, using the python
> > bindings.  i've dug around in the source, and docs, and don't see a good
> > way to do it without an exhaustive search. is there a better solution,
> > any tips appreciated.
>
> svn_log won't cross the copy boundaries for you?

not afaics... but svn log doesn't need to cross copy boundaries, it can just 
get a change revision set (including copy revs) and pick off log /author from 
the revision props, it doesn't need to get the path. i'd love to be told 
otherwise ;-)

-e



---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@subversion.tigris.org
For additional commands, e-mail: dev-help@subversion.tigris.org