diff options
author | David Riebenbauer <davrieb@liegesta.at> | 2010-04-03 21:10:16 +0200 |
---|---|---|
committer | David Riebenbauer <davrieb@liegesta.at> | 2010-04-03 22:20:48 +0200 |
commit | 981400177d68a279f485727be3f013e68f0bf691 (patch) | |
tree | 228443b89edb0da20fe739c54d6b45aae5585863 /IkiWiki/Render.pm | |
parent | 628a52a6c49f5d2fc5af251f2d718c8dff5e8ed5 (diff) | |
download | ikiwiki-981400177d68a279f485727be3f013e68f0bf691.tar ikiwiki-981400177d68a279f485727be3f013e68f0bf691.tar.gz |
Make sure deleted tag pages don't get recreated.
The reason to do this is basically a user interaction design decision.
It is achieved by adding an entry, associated to the creating plugin, to
%pagestate. To find out if files were deleted a new global hash %del_hash is
%introduced.
Diffstat (limited to 'IkiWiki/Render.pm')
-rw-r--r-- | IkiWiki/Render.pm | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/IkiWiki/Render.pm b/IkiWiki/Render.pm index fc71c8919..0c21455fb 100644 --- a/IkiWiki/Render.pm +++ b/IkiWiki/Render.pm @@ -637,12 +637,14 @@ sub refresh () { my ($changed, $internal_changed)=find_changed($files); run_hooks(needsbuild => sub { shift->($changed) }); my $oldlink_targets=calculate_old_links($changed, $del); + %del_hash = map { $_ => 1 } @{$del}; foreach my $file (@$changed) { scan($file); } - while (my $autofile = shift (@autofiles)) { + while (my $autofile = shift @{[keys %autofiles]}) { + my $plugin=$autofiles{$autofile}; my $page=pagename($autofile); if ($pages->{$page}) { debug(sprintf(gettext("%s has multiple possible source pages"), $page)); @@ -654,6 +656,7 @@ sub refresh () { push @{$changed}, $autofile if find_changed([$autofile]); scan($autofile); + delete $autofiles{$autofile}; } calculate_links(); |