aboutsummaryrefslogtreecommitdiff
path: root/doc/bugs/multiple_pages_with_same_name.mdwn
diff options
context:
space:
mode:
authorhttp://www.cse.unsw.edu.au/~willu/ <http://www.cse.unsw.edu.au/~willu/@web>2008-09-21 06:04:37 -0400
committerJoey Hess <joey@kitenet.net>2008-09-21 06:04:37 -0400
commit2f3b93a55a0a8582c00826b1f80dc4963ff0ea67 (patch)
treeaab837ad069c69469700ddf55e742333b0ab4ee9 /doc/bugs/multiple_pages_with_same_name.mdwn
parent85a0c9ad8d16ed741266ffcae1fca44c80a535df (diff)
downloadikiwiki-2f3b93a55a0a8582c00826b1f80dc4963ff0ea67.tar
ikiwiki-2f3b93a55a0a8582c00826b1f80dc4963ff0ea67.tar.gz
Add second, related, patch.
Diffstat (limited to 'doc/bugs/multiple_pages_with_same_name.mdwn')
-rw-r--r--doc/bugs/multiple_pages_with_same_name.mdwn22
1 files changed, 22 insertions, 0 deletions
diff --git a/doc/bugs/multiple_pages_with_same_name.mdwn b/doc/bugs/multiple_pages_with_same_name.mdwn
index 58a004da8..26269c9ce 100644
--- a/doc/bugs/multiple_pages_with_same_name.mdwn
+++ b/doc/bugs/multiple_pages_with_same_name.mdwn
@@ -38,3 +38,25 @@ Suggestions welcome.
is(pagename("foo.mdwn"), "foo");
is(pagename("foo/bar.mdwn"), "foo/bar");
+
+----
+
+I wonder if this patch will also be useful:
+
+ diff --git a/IkiWiki/Render.pm b/IkiWiki/Render.pm
+ index 752d176..3f1b67b 100644
+ --- a/IkiWiki/Render.pm
+ +++ b/IkiWiki/Render.pm
+ @@ -279,7 +279,11 @@ sub refresh () { #{{{
+ else {
+ $f=~s/^\Q$config{srcdir}\E\/?//;
+ push @files, $f;
+ - $exists{pagename($f)}=1;
+ + my $pagename = pagename($f);
+ + if ($exists{$pagename}) {
+ + warn(sprintf(gettext("Page %s has multiple possible source pages"), $pagename)."\n");
+ + }
+ + $exists{$pagename}=1;
+ }
+ }
+ },