| 1 |
[[!comment format=mdwn |
| 2 |
username="svetlana@192500fb6a2e2ef8e78d1a08cca64b1bca9833b9" |
| 3 |
nickname="svetlana" |
| 4 |
avatar="http://cdn.libravatar.org/avatar/5821f2dec97d186ce3b455b806d33035" |
| 5 |
subject="comment 5" |
| 6 |
date="2017-02-21T03:47:34Z" |
| 7 |
content=""" |
| 8 |
Turns out always listing backlinks (if they exist) is intended behaviour. I followed \"[[todo/allow disabling backlinks]]\" todo page by editing ~/git.ikiwiki.info/IkiWiki/Render.pm |
| 9 |
|
| 10 |
diff --git a/IkiWiki/Render.pm b/IkiWiki/Render.pm |
| 11 |
index e8ed627..6142846 100644 |
| 12 |
--- a/IkiWiki/Render.pm |
| 13 |
+++ b/IkiWiki/Render.pm |
| 14 |
@@ -1,4 +1,4 @@ |
| 15 |
-#!/usr/bin/perl |
| 16 |
+#!/usr/local/bin/perl |
| 17 |
|
| 18 |
package IkiWiki; |
| 19 |
|
| 20 |
@@ -111,7 +111,8 @@ sub genpage ($$) { |
| 21 |
} |
| 22 |
templateactions($template, $page); |
| 23 |
|
| 24 |
- my @backlinks=sort { $a->{page} cmp $b->{page} || $a->{url} cmp $b->{url} } backlinks($page); |
| 25 |
+ my @backlinks=sort { $a->{page} cmp $b->{page} || $a->{url} cmp $b->{url} } backlinks($page) |
| 26 |
+ unless defined $config{nobacklinks} && $config{nobacklinks} == 0; |
| 27 |
my ($backlinks, $more_backlinks); |
| 28 |
if (@backlinks <= $config{numbacklinks} || ! $config{numbacklinks}) { |
| 29 |
$backlinks=\@backlinks; |
| 30 |
|
| 31 |
|
| 32 |
|
| 33 |
Here is line in config: |
| 34 |
|
| 35 |
nobacklinks: 1 |
| 36 |
|
| 37 |
|
| 38 |
|
| 39 |
and then \"perl Makefile.PL ;$MAKE;$MAKE install\" . But then running 'ikiwiki --rebuild --setup ~/wiki/ikiwiki.setup' makes no difference. Why ... |
| 40 |
"""]] |