How to programmatically get SVN revision description and author in c#?

前端 未结 3 653
隐瞒了意图╮
隐瞒了意图╮ 2021-02-02 00:42

How do I programmatically get the revision description and author from the SVN server in c#?

3条回答
  •  野趣味
    野趣味 (楼主)
    2021-02-02 01:24

    I've done something similar to this a while back, we needed notification of certain repository commits.

    I ended up using SubversionNotify to do this. You could take a look at the code there and see what you can use.

    I do believe SubversionNotify is grabbing output from svnlook. Svnlook has quite a few arguments that can get what you're looking for.

    If you know the revision number and repository:

    svnlook info -r [rev#] /path/to/repo
    

    Will net you the User, Timestamp, Log message length, and the log message itself:

    bob
    2009-03-25 11:10:49 -0600 (Wed, 25 Mar 2009)
    19
    Did stuff with things.
    

提交回复
热议问题