When I create a branch off a revision of TRUNK, my resulting branch doesn't have any mergeinfo set so as far as I can tell it's impossible to figure out what revision the branch came from later.
I have some scripts that are supposed to automatically generate diffs against TRUNK later, but I don't have the revision numbers I need. If I merge with main again I'll get merginfo set so the scripts can pull it out.
Also I can do
svn merge --record-only svn+ssh://{url}/main@{revision}
This will set the revision. But it's slow and requires checking out the source and committing the change back.
I could also change the scripts to generate a diff just from the changes in the branch, unless there is mergeinfo, then fallback to diffing against trunk, but the special cases are making this awfully complicated.
Is there an easier way ?
Clarification: After doing more subversion research, I read this. What I need is a programmatic way to access the IMPLICIT mergeinfo because when you create a branch via copy, you don't get the explicit mergeinfo property.
The implicit property is effectively /TRUNK:1-BRANCHPOINT
indicating the branch has all revisions up to BRANCHPOINT
included. What I'm trying to find is that BRANCHPOINT
after the branch has been made.