X-Git-Url: http://git.vanrenterghem.biz/git.ikiwiki.info.git/blobdiff_plain/4ef96e2d9994c407f0f2f46301eb91fab6b48a37..19d8acaa95ee252e3ca2bff956ad8b5d951f1381:/IkiWiki/Plugin/svn.pm diff --git a/IkiWiki/Plugin/svn.pm b/IkiWiki/Plugin/svn.pm index 05312a1ed..262fca99a 100644 --- a/IkiWiki/Plugin/svn.pm +++ b/IkiWiki/Plugin/svn.pm @@ -7,6 +7,9 @@ use IkiWiki; use POSIX qw(setlocale LC_CTYPE); sub import { #{{{ + if (exists $IkiWiki::hooks{rcs}) { + error(gettext("cannot use multiple rcs plugins")); + } hook(type => "checkconfig", id => "svn", call => \&checkconfig); hook(type => "getsetup", id => "svn", call => \&getsetup); hook(type => "rcs", id => "rcs_update", call => \&rcs_update); @@ -22,9 +25,6 @@ sub import { #{{{ } #}}} sub checkconfig () { #{{{ - if (! defined $config{diffurl}) { - $config{diffurl}=""; - } if (! defined $config{svnpath}) { $config{svnpath}="trunk"; } @@ -318,7 +318,7 @@ sub rcs_recentchanges ($) { #{{{ $file=$1; } - my $diffurl=$config{diffurl}; + my $diffurl=defined $config{diffurl} ? $config{diffurl} : ""; $diffurl=~s/\[\[file\]\]/$file/g; $diffurl=~s/\[\[r1\]\]/$rev - 1/eg; $diffurl=~s/\[\[r2\]\]/$rev/g;