Access svn: mergeinfo with SharpSvn

I use SharpSvn to get the log for the repository. For each log entry, I can access useful information about files that have been changed (via SvnLogEventArgs.ChangedPaths), but I cannot figure out how to get the svn: mergeinfo property.

Any ideas? Thanks

+3
source share
1 answer

This is just a regular Subversion property. You can extract the value using the following bit of code:

string mergeInfo;
var client = new SvnClient();
bool success = client.GetProperty(
                        SvnTarget.FromString(fileName), 
                        "svn:mergeinfo", 
                        out mergeInfo);

Note that the GetProperty result does not indicate whether the mergeinfo property was available, but if the method call was successful. The string variable mergeInfo may be null, even if success is correct.

+4
source

Source: https://habr.com/ru/post/1723935/


All Articles