Stories
Slash Boxes
Comments
NOTE: use Perl; is on undef hiatus. You can read content, but you can't post it. More info will be forthcoming forthcomingly.

All the Perl that's Practical to Extract and Report

use Perl Log In

Log In

[ Create a new account ]

nik (3476)

nik
  nikc@cpan.org
AOL IM: nikclayton (Add Buddy, Send Message)

Journal of nik (3476)

Friday September 08, 2006
11:05 AM

SVN::Web and remote repositories

[ #30930 ]

I've had a couple of journeys in to London over the last few weeks, and I've been able to use the time on the train to include support for remote Subversion repositories in to SVN::Web.

In use it's identical to 0.49, except that you can now specify the repositories to browse using Subversion URLs.

So if you have this config fragment in your config.yaml:

      repos:
          my-repo: /path/to/my/repo

that still works. But you can now do:

      repos:
          my-repo: file:///path/to/my/repo

That's no great change. But you can also do this:

      repos:
          niks-repo: svn://jc.ngo.org.uk/
          kde-repo: svn://anonsvn.kde.org/home/kde/

to link to remote repositories and browse them. So if your favourite open source project is using Subversion, but is using SomeOther(tm) web repository browser frontend you can fix that, without insisting that they install SVN::Web :-)

Obviously, this is going to be somewhat slower, so I recommend using the caching options in SVN::Web to speed things up. Also, it only seems to work for file:/// and svn:// URIs at the moment.

See this message http://jc.ngo.org.uk/pipermail/svnweb/2006-September/000018.html for more details. The work's currently on a branch, retrievable with

svn checkout svn://jc.ngo.org.uk/nik/CPAN/SVN-Web/branches/svn_ra/

Feedback welcomed.

The Fine Print: The following comments are owned by whoever posted them. We are not responsible for them in any way.
 Full
 Abbreviated
 Hidden
More | Login | Reply
Loading... please wait.
  • I feel your pain. I think the SVN API, and its bindings are quite a bit much less than stellar or intuitive.

    Just for the sake of saying so, It is possible to browse using file, svn, AND http in http://search.cpan.org/~claco/Catalyst-Model-SVN-0.05/ [cpan.org]

    That's what powers http://handelframework.com/source/ [handelframework.com]

    It wasn't fun, and it wasn't pretty, but it does work. My biggest beef is the fetching content/logs on a tab/branch url. I can't just ask for it by url, since it's a copy; you have to stroll through the logs til
    • Just for the sake of saying so, It is possible to browse using file, svn, AND http in http://search.cpan.org/~claco/Catalyst-Model-SVN-0.05/ [cpan.org]

      Do you see much use of the http:/// [http] access? I've done some benchmarking comparing SVN::Repos (file:/// only) with SVN::Ra (file:/// and svn://). Carrying out 11 runs each of SVN::Web's test suite, SVN::Ra takes about 15% longer to run the tests than SVN::Repos.

      x SVN::Repos
      + SVN::Ra
      : = Mean
      M = Median
      +----------------------------------------------------------------

      • I've got nothing. I chose SVN::Client because it was the only one that had any decent pod. And I use Ra to get_latest_version from the repo since I couldn't find another way to do it using Client. And Ra totally baffles me to this day.

        The SVN Perl bindings are not so readable. Trolling through C source docs/doxygen (when it works) isn't my idea of usable pod w/ examples. :-)

        I was under the impression that Ra, or at least it's perl bindings couldn't do all forms of connections (svn, file, http). I'm sure htt
        • The SVN Perl bindings are not so readable. Trolling through C source docs/doxygen (when it works) isn't my idea of usable pod w/ examples. :-)

          That has recently (like, last week) improved, as a big commit was made to Subversion to expand on the Perl documentation and provide more examples.

          But yes, I've often had to fallback to writing a short hack to exercise a particular API function and use Data::Dumper on the result to divine what's being returned.

          I was under the impression that Ra, or at least it's

  • This is great. It always bugged me when people would send me to a raw SVN repo URI without a useful web interface laid over it; no need to be annoyed about it any longer I guess. Thanks! :-)