summaryrefslogtreecommitdiff
path: root/IkiWiki
diff options
context:
space:
mode:
authorjoey <joey@0fa5a96a-9a0e-0410-b3b2-a0fd24251071>2006-12-28 22:15:38 +0000
committerjoey <joey@0fa5a96a-9a0e-0410-b3b2-a0fd24251071>2006-12-28 22:15:38 +0000
commit8323bc5214bf3581ebfbad57385934033c228b76 (patch)
tree5383d606c42815f5509507c5c09a48cb2ffc0de8 /IkiWiki
parent4381a2e9f733d7b4fd97e7ad1c4aeda03f239b9c (diff)
* Improve code that ignores files in the underlaydir if the srcdir has a
file building the same page. Now it will work even if the extensions of the source files differ.
Diffstat (limited to 'IkiWiki')
-rw-r--r--IkiWiki/Render.pm11
1 files changed, 7 insertions, 4 deletions
diff --git a/IkiWiki/Render.pm b/IkiWiki/Render.pm
index 863964207..678075b82 100644
--- a/IkiWiki/Render.pm
+++ b/IkiWiki/Render.pm
@@ -247,13 +247,16 @@ sub refresh () { #{{{
warn("skipping bad filename $_\n");
}
else {
- # Don't add files that are in the
+ # Don't add pages that are in the
# srcdir.
$f=~s/^\Q$config{underlaydir}\E\/?//;
if (! -e "$config{srcdir}/$f" &&
! -l "$config{srcdir}/$f") {
- push @files, $f;
- $exists{pagename($f)}=1;
+ my $page=pagename($f);
+ if (! $exists{$page}) {
+ push @files, $f;
+ $exists{$page}=1;
+ }
}
}
}
@@ -266,10 +269,10 @@ sub refresh () { #{{{
my @add;
foreach my $file (@files) {
my $page=pagename($file);
+ $pagesources{$page}=$file;
if (! $oldpagemtime{$page}) {
push @add, $file;
$pagecase{lc $page}=$page;
- $pagesources{$page}=$file;
if ($config{getctime} && -e "$config{srcdir}/$file") {
$pagectime{$page}=rcs_getctime("$config{srcdir}/$file");
}