summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJoey Hess <joey@gnu.kitenet.net>2009-10-06 17:47:10 -0400
committerJoey Hess <joey@gnu.kitenet.net>2009-10-06 17:47:10 -0400
commitaf85f62d6fd7c3b437fa527bff3392616d3513dc (patch)
treedaab5eee17d66343c7dad496f1d767333a80f9da
parent2494a23fdd911eb7e85f2ea66607b4e08d87e927 (diff)
linkmap: Use a combination of presence and link dependencies.
This makes the map be regenerated much less frequently, so larger maps are more practical to use now.
-rw-r--r--IkiWiki/Plugin/linkmap.pm6
-rw-r--r--debian/changelog3
-rw-r--r--doc/ikiwiki/directive/linkmap.mdwn4
3 files changed, 7 insertions, 6 deletions
diff --git a/IkiWiki/Plugin/linkmap.pm b/IkiWiki/Plugin/linkmap.pm
index d0671ae0e..d7ba68da9 100644
--- a/IkiWiki/Plugin/linkmap.pm
+++ b/IkiWiki/Plugin/linkmap.pm
@@ -28,9 +28,9 @@ sub preprocess (@) {
$params{pages}="*" unless defined $params{pages};
- # Needs to update whenever a page is added, removed, or
- # its links change, so register a dependency.
- add_depends($params{page}, $params{pages});
+ # Needs to update whenever a relevant page is added, or removed, or
+ # its links change.
+ add_depends($params{page}, $params{pages}, presence => 1, links => 1);
# Can't just return the linkmap here, since the htmlscrubber
# scrubs out all <object> tags (with good reason!)
diff --git a/debian/changelog b/debian/changelog
index 89d377769..a006d3177 100644
--- a/debian/changelog
+++ b/debian/changelog
@@ -26,6 +26,9 @@ ikiwiki (3.14159266) UNRELEASED; urgency=low
This makes them more efficient. It also fixes a longstanding bug,
where if only a small set of pages were considered by orphans/pagestats,
changes to links on other pages failed to cause an update.
+ * linkmap: Use a combination of presence and link dependencies.
+ This makes the map be regenerated much less frequently, so larger
+ maps are more practical to use now.
* Transitive dependencies are now correctly supported.
* Rebuild wikis on upgrade to this version to get improved dependency
info.
diff --git a/doc/ikiwiki/directive/linkmap.mdwn b/doc/ikiwiki/directive/linkmap.mdwn
index db79a1491..38cf0fd11 100644
--- a/doc/ikiwiki/directive/linkmap.mdwn
+++ b/doc/ikiwiki/directive/linkmap.mdwn
@@ -9,9 +9,7 @@ Only links between mapped pages will be shown; links pointing to or from
unmapped pages will be omitted. If the pages to include are not specified,
the links between all pages (and other files) in the wiki are mapped. For
best results, only a small set of pages should be mapped, since otherwise
-the map can become very large, unwieldy, and complicated. Also, the map is
-rebuilt whenever one of the mapped pages is changed, which can make the
-wiki a bit slow.
+the map can become very large, unwieldy, and complicated.
Here are descriptions of all the supported parameters to the `linkmap`
directive: