Recent changes to this wiki:

comment
diff --git a/doc/forum/table_plugin_and_Markdown_side_effects_on_data/comment_1_eb64f21d919b6d40a5f158683779e03f._comment b/doc/forum/table_plugin_and_Markdown_side_effects_on_data/comment_1_eb64f21d919b6d40a5f158683779e03f._comment
new file mode 100644
index 0000000..ace732b
--- /dev/null
+++ b/doc/forum/table_plugin_and_Markdown_side_effects_on_data/comment_1_eb64f21d919b6d40a5f158683779e03f._comment
@@ -0,0 +1,8 @@
+[[!comment format=mdwn
+ username="joey"
+ subject="""comment 1"""
+ date="2016-05-29T19:32:58Z"
+ content="""
+It'd be fine to add a parameter like raw=yes to the table directive to turn
+off htmlization and preprocessing of cell contents.
+"""]]

start discussion on table plugin and Markdown side effects on data
diff --git a/doc/forum/table_plugin_and_Markdown_side_effects_on_data.mdwn b/doc/forum/table_plugin_and_Markdown_side_effects_on_data.mdwn
new file mode 100644
index 0000000..1b09b8e
--- /dev/null
+++ b/doc/forum/table_plugin_and_Markdown_side_effects_on_data.mdwn
@@ -0,0 +1 @@
+I'm running 3.20130904.1ubuntu1 on Ubuntu 14.04 and have a slight problem with the [[plugins/table]] plugin because my TSV file contains cells that start with a "#" (IRC channel names) and the "#" is replaced with an `<h1>` tag. For now I decided to [hack my local installation of ikiwiki](https://github.com/pdurbin/wiki/commit/6addbf7) to replace "#" with the equivalent HTML entity, but I'd be curious to hear some discussion on this problem. I like having my TSV go through the Markdown rendering so that the URLs in the TSV are turned into clickable links. <http://wiki.greptilian.com/haunts> is where you can see me using the table plugin. The hack is in place so that the cells that start with "#" are not turned into `<h1>` tags. I don't particularly want to change my TSV data itself since I want to treat it as data and not introduce HTML entities or some other hacks in the data itself. I guess I just want some more flexibility from the table plugin on how the data is processed as Markdown. Any thoughts on all of this? -- [[users/pdurbin]]

diff --git a/doc/sandbox/discussion.mdwn b/doc/sandbox/discussion.mdwn
index ec651a5..d6a3766 100644
--- a/doc/sandbox/discussion.mdwn
+++ b/doc/sandbox/discussion.mdwn
@@ -5,3 +5,5 @@ Whilst discussing Ikiwiki on IRC, someone pointed out that "This is the SandBox,
 > `nofollow` configuration, so edits to that wiki aren't archived
 > in ikiwiki's git history forever; perhaps with a cron job to
 > reset the sandbox every few days? --[[smcv]]
+
+I've no idea what the hell you guys are talking about. I don't give a shit. I'm just trying out ikiwiki :) 

diff --git a/doc/sandbox.mdwn b/doc/sandbox.mdwn
index 038412d..d7f866c 100644
--- a/doc/sandbox.mdwn
+++ b/doc/sandbox.mdwn
@@ -1,3 +1,7 @@
+###Is this a heading? 
+
+Sure it is. 
+
 Nope my friend.
 
 <<<<<<< HEAD

diff --git a/doc/sandbox/pagestats.mdwn b/doc/sandbox/pagestats.mdwn
index 022e771..45beda9 100644
--- a/doc/sandbox/pagestats.mdwn
+++ b/doc/sandbox/pagestats.mdwn
@@ -1,5 +1,3 @@
-[[tagging]] should be in this list, since it is tagged 'branches':
-
-Everything tagged foo:
+[[tagging]] should be in this list, since it is tagged 'foo':
 
 [[!inline pages="tagged(foo)" archive="yes"]]

diff --git a/doc/sandbox/pagestats.mdwn b/doc/sandbox/pagestats.mdwn
new file mode 100644
index 0000000..022e771
--- /dev/null
+++ b/doc/sandbox/pagestats.mdwn
@@ -0,0 +1,5 @@
+[[tagging]] should be in this list, since it is tagged 'branches':
+
+Everything tagged foo:
+
+[[!inline pages="tagged(foo)" archive="yes"]]

diff --git a/doc/sandbox/tagging.mdwn b/doc/sandbox/tagging.mdwn
index 4467f0a..39a3355 100644
--- a/doc/sandbox/tagging.mdwn
+++ b/doc/sandbox/tagging.mdwn
@@ -1,5 +1,5 @@
 [[!tag foo]]
 
-I'm linking to [[patch]] but I have a taglink to [[!taglink branches]]. I also have a hidden *foo* tag.
+I'm linking to [[patch]] but I have a taglink to [[!taglink branches]]. I also have a hidden *foo* tag. I link to the non-existing page [[bar]].
 
 \[[!inline pages="tagged(branches)" archive="yes"]]

diff --git a/doc/sandbox/tagging.mdwn b/doc/sandbox/tagging.mdwn
index 1dda39a..4467f0a 100644
--- a/doc/sandbox/tagging.mdwn
+++ b/doc/sandbox/tagging.mdwn
@@ -1,3 +1,5 @@
-I'm linking to [[patch]] but I have a taglink to [[!taglink branches]].
+[[!tag foo]]
 
-[[!inline pages="tagged(branches)" archive="yes"]]
+I'm linking to [[patch]] but I have a taglink to [[!taglink branches]]. I also have a hidden *foo* tag.
+
+\[[!inline pages="tagged(branches)" archive="yes"]]

diff --git a/doc/sandbox/tagging.mdwn b/doc/sandbox/tagging.mdwn
index 5fdb9ce..1dda39a 100644
--- a/doc/sandbox/tagging.mdwn
+++ b/doc/sandbox/tagging.mdwn
@@ -1 +1,3 @@
 I'm linking to [[patch]] but I have a taglink to [[!taglink branches]].
+
+[[!inline pages="tagged(branches)" archive="yes"]]

diff --git a/doc/sandbox/tagging.mdwn b/doc/sandbox/tagging.mdwn
new file mode 100644
index 0000000..5fdb9ce
--- /dev/null
+++ b/doc/sandbox/tagging.mdwn
@@ -0,0 +1 @@
+I'm linking to [[patch]] but I have a taglink to [[!taglink branches]].

fix system calls
diff --git a/doc/plugins/contrib/irker.mdwn b/doc/plugins/contrib/irker.mdwn
index bbc24e5..603ee0d 100644
--- a/doc/plugins/contrib/irker.mdwn
+++ b/doc/plugins/contrib/irker.mdwn
@@ -108,14 +108,14 @@ sub genwrapper() {
             symlink($config{'irker_hook'}, $repo . '/hooks/post-receive') || error('failed to symlink: $!');
         }
         my $channels = join(",", @{$config{'irker_channels'}});
-        exec { 'git' } ('config', '-C', $repo, 'config', 'irker.channels', $channels);
-        exec { 'git' } ('config', '-C', $repo, 'config', 'irker.channels', $config{'wikiname'});
+        system { 'git' } ('config', '-C', $repo, 'config', 'irker.channels', $channels);
+        system { 'git' } ('config', '-C', $repo, 'config', 'irker.channels', $config{'wikiname'});
         if ($config{'irker_template'}) {
             exec { 'git' } ('config', '-C', $repo, 'config', 'irker.channels', $config{'irker_template'});
         }
     }
     else {
-        exec { 'git' } ('config', '-C', $repo, 'config', '--remove-section', 'irker');
+        system { 'git' } ('config', '-C', $repo, 'config', '--remove-section', 'irker');
         if (-l $repo . '/hooks/post-receive' && 
             readlink($repo . '/hooks/post-receive') =~ m/irkerhook/) {
             unlink($repo . '/hooks/post-receive');

No, this page is not C++ source code.
This reverts commit c35ab1e75394bd15788bd2479ad11f70c543ce78
diff --git a/doc/bugs/garbled_non-ascii_characters_in_body_in_web_interface.cpp b/doc/bugs/garbled_non-ascii_characters_in_body_in_web_interface.cpp
deleted file mode 100644
index 657b86b..0000000
--- a/doc/bugs/garbled_non-ascii_characters_in_body_in_web_interface.cpp
+++ /dev/null
@@ -1,126 +0,0 @@
-since my latest jessie upgrade here, charsets are all broken when editing a page. the page i'm trying to edit is [this wishlist](http://anarc.at/wishlist/), and it used to work fine. now, instead of:
-
-`Voici des choses que vous pouvez m'acheter si vous êtes le Père Nowel (yeah right):`
-
-... as we see in the rendered body right now, when i edit the page i see:
-
-`Voici des choses que vous pouvez m'acheter si vous �tes le P�re Nowel (yeah right):`
-
-... a typical double-encoding nightmare. The actual binary data is this for the word "Père" according to `hd`:
-
-~~~~
-anarcat@marcos:ikiwiki$ echo "Père" | hd
-00000000  50 c3 a8 72 65 0a                                 |P..re.|
-00000006
-anarcat@marcos:ikiwiki$ echo "P�re" | hd
-00000000  50 ef bf bd 72 65 0a                              |P...re.|
-00000007
-~~~~
-
-> I don't know what that is, but it isn't the usual double-UTF-8 encoding:
->
->     >>> u'è'.encode('utf-8')
->     '\xc3\xa8'
->     >>> u'è'.encode('utf-8').decode('latin-1').encode('utf-8')
->     '\xc3\x83\xc2\xa8'
->
-> A packet capture of the incorrect HTTP request/response headers and body
-> might be enlightening? --[[smcv]]
->
-> > Here are the headers according to chromium:
-> > 
-> > ~~~~
-> > GET /ikiwiki.cgi?do=edit&page=wishlist HTTP/1.1
-> > Host: anarc.at
-> > Connection: keep-alive
-> > Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8
-> > User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/35.0.1916.153 Safari/537.36
-> > Referer: http://anarc.at/wishlist/
-> > Accept-Encoding: gzip,deflate,sdch
-> > Accept-Language: fr,en-US;q=0.8,en;q=0.6
-> > Cookie: openid_provider=openid; ikiwiki_session_anarcat=XXXXXXXXXXXXXXXXXXXXXXX
-> > 
-> > HTTP/1.1 200 OK
-> > Date: Mon, 08 Sep 2014 21:22:24 GMT
-> > Server: Apache/2.4.10 (Debian)
-> > Set-Cookie: ikiwiki_session_anarcat=XXXXXXXXXXXXXXXXXXXXXXX; path=/; HttpOnly
-> > Vary: Accept-Encoding
-> > Content-Encoding: gzip
-> > Content-Length: 4093
-> > Keep-Alive: timeout=5, max=100
-> > Connection: Keep-Alive
-> > Content-Type: text/html; charset=utf-8
-> > ~~~~
-> > 
-> > ... which seem fairly normal... getting more data than this is a little inconvenient since the data is gzip-encoded and i'm kind of lazy extracting that from the stream. Chromium does seem to auto-detect it as utf8 according to the menus however... not sure what's going on here. I would focus on the following error however, since it's clearly emanating from the CGI... --[[anarcat]]
-
-Clicking on the Cancel button yields the following warning:
-
-~~~~
-Error: Cannot decode string with wide characters at /usr/lib/x86_64-linux-gnu/perl/5.20/Encode.pm line 215.
-~~~~
-
-> Looks as though you might be able to get a Python-style backtrace for this
-> by setting `$Carp::Verbose = 1`.
->
-> The error is that we're taking some string (which string? only a backtrace
-> would tell you) that is already flagged as Unicode, and trying to decode
-> it from byte-blob to Unicode again, analogous to this Python:
->
->     some_bytes.decode('utf-8').decode('utf-8')
->
-> --[[smcv]]
-> > 
-> > I couldn't figure out where to set that Carp thing - it doesn't work simply by setting it in /usr/bin/ikiwiki - so i am not sure how to use this. However, with some debugging code in Encode.pm, i was able to find a case of double-encoding - in the left menu, for example, which is the source of the Encode.pm crash.
-> > 
-> > It seems that some unicode semantics changed in Perl 5.20, or more precisely, in Encode.pm 2.53, according to [this](https://code.activestate.com/lists/perl-unicode/3314/). 5.20 does have significant Unicode changes, but I am not sure they are related (see [perldelta](https://metacpan.org/pod/distribution/perl/pod/perldelta.pod)). Doing more archeology, it seems that Encode.pm is indeed where the problem started, all the way back in [commit 8005a82](https://github.com/dankogai/p5-encode/commit/8005a82d8aa83024d72b14e66d9eb97d82029eeb#diff-f3330aa405ffb7e3fec2395c1fc953ac) (august 2013), taken from [pull request #11](https://github.com/dankogai/p5-encode/pull/11) which expressively forbids double-decoding, in effect failing like python does in the above example you gave (Perl used to silently succeed instead, a rather big change if you ask me).
-> > 
-> > So stepping back, it seems that this would be a bug in Ikiwiki. It could be in any of those places:
-> > 
-> > ~~~~
-> > anarcat@marcos:ikiwiki$ grep -r decode_utf8 IkiWiki* | wc -l
-> > 31
-> > ~~~~
-> > 
-> > Now the fun part is to determine which one should be turned off... or should we duplicate the logic that was removed in decode_utf8, or make a safe_decode_utf8 for ourselves? --[[anarcat]]
-
-The apache logs yield:
-
-~~~~
-[Mon Sep 08 16:17:43.995827 2014] [cgi:error] [pid 2609] [client 192.168.0.3:47445] AH01215: Died at /usr/share/perl5/IkiWiki/CGI.pm line 467., referer: http://anarc.at/ikiwiki.cgi?do=edit&page=wishlist
-~~~~
-
-Interestingly enough, I can't reproduce the bug here (at least in this page). Also, editing the page through git works fine.
-
-I had put ikiwiki on hold during the last upgrade, so it was upgraded separately. The bug happens both with 3.20140613 and 3.20140831. The major thing that happened today is the upgrade from perl 5.18 to 5.20. Here's the output of `egrep '[0-9] (remove|purge|install|upgrade)' /var/log/dpkg.log | pastebinit -b paste.debian.net` to give an idea of what was upgraded today:
-
-http://paste.debian.net/plain/119944
-
-This is a major bug which should probably be fixed before jessie, yet i can't seem to find a severity statement in reportbug that would justify blocking the release based on this - unless we consider non-english speakers as "most" users (i don't know the demographics well enough). It certainly makes ikiwiki completely unusable for my users that operate on the web interface in french... --[[anarcat]]
-
-Note that on this one page, i can't even get the textarea to display and i immediately get `Error: Cannot decode string with wide characters at /usr/lib/x86_64-linux-gnu/perl/5.20/Encode.pm line 215`: http://anarc.at/ikiwiki.cgi?do=edit&page=hardware%2Fserver%2Fmarcos.
-
-Also note that this is the same as [[forum/"Error: cannot decode string with wide characters" on Mageia Linux x86-64 Cauldron]], I believe. The backtrace I get here is:
-
-~~~~
-Error: Cannot decode string with wide characters at /usr/lib/x86_64-linux-gnu/perl/5.20/Encode.pm line 215. Encode::decode_utf8("**Menu**\x{d}\x{a}\x{d}\x{a} * [[\x{fffd} propos|index]]\x{d}\x{a} * [[Logiciels|software]]"...)
-called at /usr/share/perl5/IkiWiki/CGI.pm line 117 IkiWiki::decode_form_utf8(CGI::FormBuilder=HASH(0x2ad63b8))
-called at /usr/share/perl5/IkiWiki/Plugin/editpage.pm line 90 IkiWiki::cgi_editpage(CGI=HASH(0xd514f8), CGI::Session=HASH(0x27797e0))
-called at /usr/share/perl5/IkiWiki/CGI.pm line 443 IkiWiki::__ANON__(CODE(0xfaa460))
-called at /usr/share/perl5/IkiWiki.pm line 2101 IkiWiki::run_hooks("sessioncgi", CODE(0x2520138))
-called at /usr/share/perl5/IkiWiki/CGI.pm line 443 IkiWiki::cgi()
-called at /usr/bin/ikiwiki line 192 eval {...}
-called at /usr/bin/ikiwiki line 192 IkiWiki::main()
-called at /usr/bin/ikiwiki line 231
-~~~~
-
-so this would explain the error on cancel, but doesn't explain the weird encoding i get when editing the page... <sigh>...
-
-... and that leads me to this crazy patch which fixes all the above issue, by avoiding double-decoding... go figure that shit out...
-
-[[!template  id=gitbranch branch=anarcat/dev/safe_unicode author="[[anarcat]]"]] 
-
-> [[Looks good to me|users/smcv/ready]] although I'm not sure how valuable
-> the `$] < 5.02 || ` test is - I'd be tempted to just call `is_utf8`. --[[smcv]]
-
->> [[merged|done]] --[[smcv]]
diff --git a/doc/bugs/garbled_non-ascii_characters_in_body_in_web_interface.mdwn b/doc/bugs/garbled_non-ascii_characters_in_body_in_web_interface.mdwn
new file mode 100644
index 0000000..657b86b
--- /dev/null
+++ b/doc/bugs/garbled_non-ascii_characters_in_body_in_web_interface.mdwn
@@ -0,0 +1,126 @@
+since my latest jessie upgrade here, charsets are all broken when editing a page. the page i'm trying to edit is [this wishlist](http://anarc.at/wishlist/), and it used to work fine. now, instead of:
+
+`Voici des choses que vous pouvez m'acheter si vous êtes le Père Nowel (yeah right):`
+
+... as we see in the rendered body right now, when i edit the page i see:
+
+`Voici des choses que vous pouvez m'acheter si vous �tes le P�re Nowel (yeah right):`
+
+... a typical double-encoding nightmare. The actual binary data is this for the word "Père" according to `hd`:
+
+~~~~
+anarcat@marcos:ikiwiki$ echo "Père" | hd
+00000000  50 c3 a8 72 65 0a                                 |P..re.|
+00000006
+anarcat@marcos:ikiwiki$ echo "P�re" | hd
+00000000  50 ef bf bd 72 65 0a                              |P...re.|
+00000007
+~~~~
+
+> I don't know what that is, but it isn't the usual double-UTF-8 encoding:
+>
+>     >>> u'è'.encode('utf-8')
+>     '\xc3\xa8'
+>     >>> u'è'.encode('utf-8').decode('latin-1').encode('utf-8')
+>     '\xc3\x83\xc2\xa8'
+>
+> A packet capture of the incorrect HTTP request/response headers and body
+> might be enlightening? --[[smcv]]
+>
+> > Here are the headers according to chromium:
+> > 
+> > ~~~~
+> > GET /ikiwiki.cgi?do=edit&page=wishlist HTTP/1.1
+> > Host: anarc.at
+> > Connection: keep-alive
+> > Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8
+> > User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/35.0.1916.153 Safari/537.36
+> > Referer: http://anarc.at/wishlist/
+> > Accept-Encoding: gzip,deflate,sdch
+> > Accept-Language: fr,en-US;q=0.8,en;q=0.6
+> > Cookie: openid_provider=openid; ikiwiki_session_anarcat=XXXXXXXXXXXXXXXXXXXXXXX
+> > 
+> > HTTP/1.1 200 OK
+> > Date: Mon, 08 Sep 2014 21:22:24 GMT
+> > Server: Apache/2.4.10 (Debian)
+> > Set-Cookie: ikiwiki_session_anarcat=XXXXXXXXXXXXXXXXXXXXXXX; path=/; HttpOnly
+> > Vary: Accept-Encoding
+> > Content-Encoding: gzip
+> > Content-Length: 4093
+> > Keep-Alive: timeout=5, max=100
+> > Connection: Keep-Alive
+> > Content-Type: text/html; charset=utf-8
+> > ~~~~
+> > 
+> > ... which seem fairly normal... getting more data than this is a little inconvenient since the data is gzip-encoded and i'm kind of lazy extracting that from the stream. Chromium does seem to auto-detect it as utf8 according to the menus however... not sure what's going on here. I would focus on the following error however, since it's clearly emanating from the CGI... --[[anarcat]]
+
+Clicking on the Cancel button yields the following warning:
+
+~~~~
+Error: Cannot decode string with wide characters at /usr/lib/x86_64-linux-gnu/perl/5.20/Encode.pm line 215.
+~~~~
+

(Diff truncated)
This reverts commit cfc5d5d9ed1a5c76212fecd592639aaa3de9b784
diff --git a/doc/index.c b/doc/index.c
deleted file mode 100644
index e0e4016..0000000
--- a/doc/index.c
+++ /dev/null
@@ -1,37 +0,0 @@
-[[!template id=links]]
-
-Ikiwiki is a **wiki compiler**. It converts wiki pages into HTML pages
-suitable for publishing on a website. Ikiwiki stores pages and history in a
-[[revision_control_system|rcs]] such as [[Subversion|rcs/svn]] or [[rcs/Git]].
-There are many other [[features]], including support for
-[[blogging|blog]] and [[podcasting|podcast]], as well as a large
-array of [[plugins]].
-
-Alternatively, think of ikiwiki as a particularly flexible static
-site generator with some dynamic features.
-
-
-
-## using ikiwiki
-
-[[Setup]] has a tutorial for setting up ikiwiki, or you can read the
-[[man_page|usage]]. There are some [[examples]] of things you can do
-with ikiwiki, and some [[tips]].  Basic documentation for ikiwiki plugins
-and syntax is provided [[here|ikiwiki]]. The [[forum]] is open for
-discussions.
-
-All wikis are supposed to have a [[sandbox]], so this one does too.
-
-This site generally runs the latest release of ikiwiki; currently, it runs
-ikiwiki [[!version ]].
-
-## developer resources
-
-The [[RoadMap]] describes where the project is going.
-[[Bugs]], [[TODO]] items, [[wishlist]] items, and [[patches|patch]]
-can be submitted and tracked using this wiki.
-
-Ikiwiki is developed by [[Joey]] and many contributors,
-and is [[FreeSoftware]].
-
-
diff --git a/doc/index.mdwn b/doc/index.mdwn
new file mode 100644
index 0000000..e0e4016
--- /dev/null
+++ b/doc/index.mdwn
@@ -0,0 +1,37 @@
+[[!template id=links]]
+
+Ikiwiki is a **wiki compiler**. It converts wiki pages into HTML pages
+suitable for publishing on a website. Ikiwiki stores pages and history in a
+[[revision_control_system|rcs]] such as [[Subversion|rcs/svn]] or [[rcs/Git]].
+There are many other [[features]], including support for
+[[blogging|blog]] and [[podcasting|podcast]], as well as a large
+array of [[plugins]].
+
+Alternatively, think of ikiwiki as a particularly flexible static
+site generator with some dynamic features.
+
+
+
+## using ikiwiki
+
+[[Setup]] has a tutorial for setting up ikiwiki, or you can read the
+[[man_page|usage]]. There are some [[examples]] of things you can do
+with ikiwiki, and some [[tips]].  Basic documentation for ikiwiki plugins
+and syntax is provided [[here|ikiwiki]]. The [[forum]] is open for
+discussions.
+
+All wikis are supposed to have a [[sandbox]], so this one does too.
+
+This site generally runs the latest release of ikiwiki; currently, it runs
+ikiwiki [[!version ]].
+
+## developer resources
+
+The [[RoadMap]] describes where the project is going.
+[[Bugs]], [[TODO]] items, [[wishlist]] items, and [[patches|patch]]
+can be submitted and tracked using this wiki.
+
+Ikiwiki is developed by [[Joey]] and many contributors,
+and is [[FreeSoftware]].
+
+

rename bugs/garbled_non-ascii_characters_in_body_in_web_interface.mdwn to bugs/garbled_non-ascii_characters_in_body_in_web_interface.cpp
diff --git a/doc/bugs/garbled_non-ascii_characters_in_body_in_web_interface.cpp b/doc/bugs/garbled_non-ascii_characters_in_body_in_web_interface.cpp
new file mode 100644
index 0000000..657b86b
--- /dev/null
+++ b/doc/bugs/garbled_non-ascii_characters_in_body_in_web_interface.cpp
@@ -0,0 +1,126 @@
+since my latest jessie upgrade here, charsets are all broken when editing a page. the page i'm trying to edit is [this wishlist](http://anarc.at/wishlist/), and it used to work fine. now, instead of:
+
+`Voici des choses que vous pouvez m'acheter si vous êtes le Père Nowel (yeah right):`
+
+... as we see in the rendered body right now, when i edit the page i see:
+
+`Voici des choses que vous pouvez m'acheter si vous �tes le P�re Nowel (yeah right):`
+
+... a typical double-encoding nightmare. The actual binary data is this for the word "Père" according to `hd`:
+
+~~~~
+anarcat@marcos:ikiwiki$ echo "Père" | hd
+00000000  50 c3 a8 72 65 0a                                 |P..re.|
+00000006
+anarcat@marcos:ikiwiki$ echo "P�re" | hd
+00000000  50 ef bf bd 72 65 0a                              |P...re.|
+00000007
+~~~~
+
+> I don't know what that is, but it isn't the usual double-UTF-8 encoding:
+>
+>     >>> u'è'.encode('utf-8')
+>     '\xc3\xa8'
+>     >>> u'è'.encode('utf-8').decode('latin-1').encode('utf-8')
+>     '\xc3\x83\xc2\xa8'
+>
+> A packet capture of the incorrect HTTP request/response headers and body
+> might be enlightening? --[[smcv]]
+>
+> > Here are the headers according to chromium:
+> > 
+> > ~~~~
+> > GET /ikiwiki.cgi?do=edit&page=wishlist HTTP/1.1
+> > Host: anarc.at
+> > Connection: keep-alive
+> > Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8
+> > User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/35.0.1916.153 Safari/537.36
+> > Referer: http://anarc.at/wishlist/
+> > Accept-Encoding: gzip,deflate,sdch
+> > Accept-Language: fr,en-US;q=0.8,en;q=0.6
+> > Cookie: openid_provider=openid; ikiwiki_session_anarcat=XXXXXXXXXXXXXXXXXXXXXXX
+> > 
+> > HTTP/1.1 200 OK
+> > Date: Mon, 08 Sep 2014 21:22:24 GMT
+> > Server: Apache/2.4.10 (Debian)
+> > Set-Cookie: ikiwiki_session_anarcat=XXXXXXXXXXXXXXXXXXXXXXX; path=/; HttpOnly
+> > Vary: Accept-Encoding
+> > Content-Encoding: gzip
+> > Content-Length: 4093
+> > Keep-Alive: timeout=5, max=100
+> > Connection: Keep-Alive
+> > Content-Type: text/html; charset=utf-8
+> > ~~~~
+> > 
+> > ... which seem fairly normal... getting more data than this is a little inconvenient since the data is gzip-encoded and i'm kind of lazy extracting that from the stream. Chromium does seem to auto-detect it as utf8 according to the menus however... not sure what's going on here. I would focus on the following error however, since it's clearly emanating from the CGI... --[[anarcat]]
+
+Clicking on the Cancel button yields the following warning:
+
+~~~~
+Error: Cannot decode string with wide characters at /usr/lib/x86_64-linux-gnu/perl/5.20/Encode.pm line 215.
+~~~~
+
+> Looks as though you might be able to get a Python-style backtrace for this
+> by setting `$Carp::Verbose = 1`.
+>
+> The error is that we're taking some string (which string? only a backtrace
+> would tell you) that is already flagged as Unicode, and trying to decode
+> it from byte-blob to Unicode again, analogous to this Python:
+>
+>     some_bytes.decode('utf-8').decode('utf-8')
+>
+> --[[smcv]]
+> > 
+> > I couldn't figure out where to set that Carp thing - it doesn't work simply by setting it in /usr/bin/ikiwiki - so i am not sure how to use this. However, with some debugging code in Encode.pm, i was able to find a case of double-encoding - in the left menu, for example, which is the source of the Encode.pm crash.
+> > 
+> > It seems that some unicode semantics changed in Perl 5.20, or more precisely, in Encode.pm 2.53, according to [this](https://code.activestate.com/lists/perl-unicode/3314/). 5.20 does have significant Unicode changes, but I am not sure they are related (see [perldelta](https://metacpan.org/pod/distribution/perl/pod/perldelta.pod)). Doing more archeology, it seems that Encode.pm is indeed where the problem started, all the way back in [commit 8005a82](https://github.com/dankogai/p5-encode/commit/8005a82d8aa83024d72b14e66d9eb97d82029eeb#diff-f3330aa405ffb7e3fec2395c1fc953ac) (august 2013), taken from [pull request #11](https://github.com/dankogai/p5-encode/pull/11) which expressively forbids double-decoding, in effect failing like python does in the above example you gave (Perl used to silently succeed instead, a rather big change if you ask me).
+> > 
+> > So stepping back, it seems that this would be a bug in Ikiwiki. It could be in any of those places:
+> > 
+> > ~~~~
+> > anarcat@marcos:ikiwiki$ grep -r decode_utf8 IkiWiki* | wc -l
+> > 31
+> > ~~~~
+> > 
+> > Now the fun part is to determine which one should be turned off... or should we duplicate the logic that was removed in decode_utf8, or make a safe_decode_utf8 for ourselves? --[[anarcat]]
+
+The apache logs yield:
+
+~~~~
+[Mon Sep 08 16:17:43.995827 2014] [cgi:error] [pid 2609] [client 192.168.0.3:47445] AH01215: Died at /usr/share/perl5/IkiWiki/CGI.pm line 467., referer: http://anarc.at/ikiwiki.cgi?do=edit&page=wishlist
+~~~~
+
+Interestingly enough, I can't reproduce the bug here (at least in this page). Also, editing the page through git works fine.
+
+I had put ikiwiki on hold during the last upgrade, so it was upgraded separately. The bug happens both with 3.20140613 and 3.20140831. The major thing that happened today is the upgrade from perl 5.18 to 5.20. Here's the output of `egrep '[0-9] (remove|purge|install|upgrade)' /var/log/dpkg.log | pastebinit -b paste.debian.net` to give an idea of what was upgraded today:
+
+http://paste.debian.net/plain/119944
+
+This is a major bug which should probably be fixed before jessie, yet i can't seem to find a severity statement in reportbug that would justify blocking the release based on this - unless we consider non-english speakers as "most" users (i don't know the demographics well enough). It certainly makes ikiwiki completely unusable for my users that operate on the web interface in french... --[[anarcat]]
+
+Note that on this one page, i can't even get the textarea to display and i immediately get `Error: Cannot decode string with wide characters at /usr/lib/x86_64-linux-gnu/perl/5.20/Encode.pm line 215`: http://anarc.at/ikiwiki.cgi?do=edit&page=hardware%2Fserver%2Fmarcos.
+
+Also note that this is the same as [[forum/"Error: cannot decode string with wide characters" on Mageia Linux x86-64 Cauldron]], I believe. The backtrace I get here is:
+
+~~~~
+Error: Cannot decode string with wide characters at /usr/lib/x86_64-linux-gnu/perl/5.20/Encode.pm line 215. Encode::decode_utf8("**Menu**\x{d}\x{a}\x{d}\x{a} * [[\x{fffd} propos|index]]\x{d}\x{a} * [[Logiciels|software]]"...)
+called at /usr/share/perl5/IkiWiki/CGI.pm line 117 IkiWiki::decode_form_utf8(CGI::FormBuilder=HASH(0x2ad63b8))
+called at /usr/share/perl5/IkiWiki/Plugin/editpage.pm line 90 IkiWiki::cgi_editpage(CGI=HASH(0xd514f8), CGI::Session=HASH(0x27797e0))
+called at /usr/share/perl5/IkiWiki/CGI.pm line 443 IkiWiki::__ANON__(CODE(0xfaa460))
+called at /usr/share/perl5/IkiWiki.pm line 2101 IkiWiki::run_hooks("sessioncgi", CODE(0x2520138))
+called at /usr/share/perl5/IkiWiki/CGI.pm line 443 IkiWiki::cgi()
+called at /usr/bin/ikiwiki line 192 eval {...}
+called at /usr/bin/ikiwiki line 192 IkiWiki::main()
+called at /usr/bin/ikiwiki line 231
+~~~~
+
+so this would explain the error on cancel, but doesn't explain the weird encoding i get when editing the page... <sigh>...
+
+... and that leads me to this crazy patch which fixes all the above issue, by avoiding double-decoding... go figure that shit out...
+
+[[!template  id=gitbranch branch=anarcat/dev/safe_unicode author="[[anarcat]]"]] 
+
+> [[Looks good to me|users/smcv/ready]] although I'm not sure how valuable
+> the `$] < 5.02 || ` test is - I'd be tempted to just call `is_utf8`. --[[smcv]]
+
+>> [[merged|done]] --[[smcv]]
diff --git a/doc/bugs/garbled_non-ascii_characters_in_body_in_web_interface.mdwn b/doc/bugs/garbled_non-ascii_characters_in_body_in_web_interface.mdwn
deleted file mode 100644
index 657b86b..0000000
--- a/doc/bugs/garbled_non-ascii_characters_in_body_in_web_interface.mdwn
+++ /dev/null
@@ -1,126 +0,0 @@
-since my latest jessie upgrade here, charsets are all broken when editing a page. the page i'm trying to edit is [this wishlist](http://anarc.at/wishlist/), and it used to work fine. now, instead of:
-
-`Voici des choses que vous pouvez m'acheter si vous êtes le Père Nowel (yeah right):`
-
-... as we see in the rendered body right now, when i edit the page i see:
-
-`Voici des choses que vous pouvez m'acheter si vous �tes le P�re Nowel (yeah right):`
-
-... a typical double-encoding nightmare. The actual binary data is this for the word "Père" according to `hd`:
-
-~~~~
-anarcat@marcos:ikiwiki$ echo "Père" | hd
-00000000  50 c3 a8 72 65 0a                                 |P..re.|
-00000006
-anarcat@marcos:ikiwiki$ echo "P�re" | hd
-00000000  50 ef bf bd 72 65 0a                              |P...re.|
-00000007
-~~~~
-
-> I don't know what that is, but it isn't the usual double-UTF-8 encoding:
->
->     >>> u'è'.encode('utf-8')
->     '\xc3\xa8'
->     >>> u'è'.encode('utf-8').decode('latin-1').encode('utf-8')
->     '\xc3\x83\xc2\xa8'
->
-> A packet capture of the incorrect HTTP request/response headers and body
-> might be enlightening? --[[smcv]]
->
-> > Here are the headers according to chromium:
-> > 
-> > ~~~~
-> > GET /ikiwiki.cgi?do=edit&page=wishlist HTTP/1.1
-> > Host: anarc.at
-> > Connection: keep-alive
-> > Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8
-> > User-Agent: Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/35.0.1916.153 Safari/537.36
-> > Referer: http://anarc.at/wishlist/
-> > Accept-Encoding: gzip,deflate,sdch
-> > Accept-Language: fr,en-US;q=0.8,en;q=0.6
-> > Cookie: openid_provider=openid; ikiwiki_session_anarcat=XXXXXXXXXXXXXXXXXXXXXXX
-> > 
-> > HTTP/1.1 200 OK
-> > Date: Mon, 08 Sep 2014 21:22:24 GMT
-> > Server: Apache/2.4.10 (Debian)
-> > Set-Cookie: ikiwiki_session_anarcat=XXXXXXXXXXXXXXXXXXXXXXX; path=/; HttpOnly
-> > Vary: Accept-Encoding
-> > Content-Encoding: gzip
-> > Content-Length: 4093
-> > Keep-Alive: timeout=5, max=100
-> > Connection: Keep-Alive
-> > Content-Type: text/html; charset=utf-8
-> > ~~~~
-> > 
-> > ... which seem fairly normal... getting more data than this is a little inconvenient since the data is gzip-encoded and i'm kind of lazy extracting that from the stream. Chromium does seem to auto-detect it as utf8 according to the menus however... not sure what's going on here. I would focus on the following error however, since it's clearly emanating from the CGI... --[[anarcat]]
-
-Clicking on the Cancel button yields the following warning:
-
-~~~~
-Error: Cannot decode string with wide characters at /usr/lib/x86_64-linux-gnu/perl/5.20/Encode.pm line 215.
-~~~~
-

(Diff truncated)
rename index.mdwn to index.c
diff --git a/doc/index.c b/doc/index.c
new file mode 100644
index 0000000..e0e4016
--- /dev/null
+++ b/doc/index.c
@@ -0,0 +1,37 @@
+[[!template id=links]]
+
+Ikiwiki is a **wiki compiler**. It converts wiki pages into HTML pages
+suitable for publishing on a website. Ikiwiki stores pages and history in a
+[[revision_control_system|rcs]] such as [[Subversion|rcs/svn]] or [[rcs/Git]].
+There are many other [[features]], including support for
+[[blogging|blog]] and [[podcasting|podcast]], as well as a large
+array of [[plugins]].
+
+Alternatively, think of ikiwiki as a particularly flexible static
+site generator with some dynamic features.
+
+
+
+## using ikiwiki
+
+[[Setup]] has a tutorial for setting up ikiwiki, or you can read the
+[[man_page|usage]]. There are some [[examples]] of things you can do
+with ikiwiki, and some [[tips]].  Basic documentation for ikiwiki plugins
+and syntax is provided [[here|ikiwiki]]. The [[forum]] is open for
+discussions.
+
+All wikis are supposed to have a [[sandbox]], so this one does too.
+
+This site generally runs the latest release of ikiwiki; currently, it runs
+ikiwiki [[!version ]].
+
+## developer resources
+
+The [[RoadMap]] describes where the project is going.
+[[Bugs]], [[TODO]] items, [[wishlist]] items, and [[patches|patch]]
+can be submitted and tracked using this wiki.
+
+Ikiwiki is developed by [[Joey]] and many contributors,
+and is [[FreeSoftware]].
+
+
diff --git a/doc/index.mdwn b/doc/index.mdwn
deleted file mode 100644
index e0e4016..0000000
--- a/doc/index.mdwn
+++ /dev/null
@@ -1,37 +0,0 @@
-[[!template id=links]]
-
-Ikiwiki is a **wiki compiler**. It converts wiki pages into HTML pages
-suitable for publishing on a website. Ikiwiki stores pages and history in a
-[[revision_control_system|rcs]] such as [[Subversion|rcs/svn]] or [[rcs/Git]].
-There are many other [[features]], including support for
-[[blogging|blog]] and [[podcasting|podcast]], as well as a large
-array of [[plugins]].
-
-Alternatively, think of ikiwiki as a particularly flexible static
-site generator with some dynamic features.
-
-
-
-## using ikiwiki
-
-[[Setup]] has a tutorial for setting up ikiwiki, or you can read the
-[[man_page|usage]]. There are some [[examples]] of things you can do
-with ikiwiki, and some [[tips]].  Basic documentation for ikiwiki plugins
-and syntax is provided [[here|ikiwiki]]. The [[forum]] is open for
-discussions.
-
-All wikis are supposed to have a [[sandbox]], so this one does too.
-
-This site generally runs the latest release of ikiwiki; currently, it runs
-ikiwiki [[!version ]].
-
-## developer resources
-
-The [[RoadMap]] describes where the project is going.
-[[Bugs]], [[TODO]] items, [[wishlist]] items, and [[patches|patch]]
-can be submitted and tracked using this wiki.
-
-Ikiwiki is developed by [[Joey]] and many contributors,
-and is [[FreeSoftware]].
-
-

diff --git a/doc/tips/monitor_page_changes_through_IRC.mdwn b/doc/tips/monitor_page_changes_through_IRC.mdwn
index d1b6113..94f0944 100644
--- a/doc/tips/monitor_page_changes_through_IRC.mdwn
+++ b/doc/tips/monitor_page_changes_through_IRC.mdwn
@@ -17,6 +17,10 @@ there are basically two alternatives now:
 * [KGB](https://kgb.alioth.debian.org/) - a Perl script that has been running at Debian since 2009
 * [irker](http://www.catb.org/esr/irker/) - a Python script whipped up by ESR in the fall of CIA.vc (~2011), ignoring the existing KGB bot
 
-KGB is harder to setup ([tutorial](https://www.donarmstrong.com/posts/switching_to_kgb/)), as it , but more reliable than irker, in my experience. I built the [[plugins/contrib/irker]] plugin to automatically configure notifications with irker. --[[anarcat]]
+KGB is harder to setup ([tutorial](https://www.donarmstrong.com/posts/switching_to_kgb/)), as it , but more reliable than irker, in my experience.
+
+I built the [[plugins/contrib/irker]] plugin to automatically configure notifications with irker. I chose irker because it could be configured per wiki, without having to touch a central configuration as would be required for KGB.--[[anarcat]]
+
+There is also a public service named [Notifico](http://n.tkte.ch/) that aims to replace the defunct [CIA.vc](http://cia.vc/) but it still requires server-side software configuration, so I think it is worth it. Same for [Pursuivant](https://martinsandsmark.wordpress.com/2012/11/20/irc-commit-notifications/). There is also a plethora of commercial notification services which are obviously not covered here.
 
 See also [[todo/ikibot]] for another bot idea.

revert test edit
This reverts commit 4a8bf62f44738fcc6c49d24295d9668bb247a88f
diff --git a/doc/ikiwiki/formatting.mdwn b/doc/ikiwiki/formatting.mdwn
index f809fff..befbce9 100644
--- a/doc/ikiwiki/formatting.mdwn
+++ b/doc/ikiwiki/formatting.mdwn
@@ -10,9 +10,6 @@ Leave blank lines between paragraphs.
 You can *\*emphasise\** or **\*\*strongly emphasise\*\*** text by placing it
 in single or double asterisks.
 
------
-**Open-source software** may be developed in a *collaborative* public manner.
----
 To create a list, start each line with an asterisk:
 
 * "* this is my list"

diff --git a/doc/ikiwiki/formatting.mdwn b/doc/ikiwiki/formatting.mdwn
index befbce9..f809fff 100644
--- a/doc/ikiwiki/formatting.mdwn
+++ b/doc/ikiwiki/formatting.mdwn
@@ -10,6 +10,9 @@ Leave blank lines between paragraphs.
 You can *\*emphasise\** or **\*\*strongly emphasise\*\*** text by placing it
 in single or double asterisks.
 
+-----
+**Open-source software** may be developed in a *collaborative* public manner.
+---
 To create a list, start each line with an asterisk:
 
 * "* this is my list"

Revert vandalism
diff --git a/doc/bugs/Anon_edit_caused_lock_out_on_entire_site_.mdwn b/doc/bugs/Anon_edit_caused_lock_out_on_entire_site_.mdwn
index a669413..f4f2f26 100644
--- a/doc/bugs/Anon_edit_caused_lock_out_on_entire_site_.mdwn
+++ b/doc/bugs/Anon_edit_caused_lock_out_on_entire_site_.mdwn
@@ -26,6 +26,10 @@ The `moderatedcomments` plugins is **not** enabled
 
 The `anonok` plugin is **not** enabled
 
+> What are your complete `add_plugins` and `disable_plugins` options?
+> Which version of ikiwiki are you running? Are you using any third-party
+> plugins or patches? --[[smcv]]
+
 ---
 
 ## Steps
@@ -57,3 +61,12 @@ For [this particular installation](https://dev.iikb.xyz), that's not the case.
 ## Question
 
 Is there a session file or something to logout this phantom user?
+
+> See [[tips/inside_dot_ikiwiki]]. `.ikiwiki/userdb` is a Perl Storable file;
+> there are instructions for inspecting it on that page. `.ikiwiki/sessions.db`
+> is most likely a Berkeley DB file.
+>
+> I would be interested to see the contents of these two files and the complete
+> `.setup` file. I would also be interested to see a tarball of the entire
+> wiki source directory, if it isn't excessively large. If you'd be willing to
+> share them, please contact <mailto:smcv@debian.org>. --[[smcv]]
diff --git a/doc/bugs/password_reset_failure.mdwn b/doc/bugs/password_reset_failure.mdwn
new file mode 100644
index 0000000..1e40981
--- /dev/null
+++ b/doc/bugs/password_reset_failure.mdwn
@@ -0,0 +1,22 @@
+I can't seem to do a password reset on this wiki. I am writing this
+through the anonymous git push interface (phew for that!).
+
+I have tried three times now to reset my password through the user
+interface - my account name is [[anarcat]], and when i do the password
+reset, I get a token. I go visit the website, set a passphrase, click
+`Save Preferences` and I end up on a login form. I enter my
+passphrase, click `Login` and I get the error:
+
+    1 error(s) were encountered with your submission. Please correct the fields highlighted below.
+    
+    Name
+    [anarcat]
+    
+    Password
+    [*************] Invalid entry
+
+`Password` is highlighted.
+
+Even if I leave the password there (my cleartext password is in the
+login form by default after the password reset, which is strange), it
+still gives me that error. -- [[anarcat]]
diff --git a/doc/plugins/contrib/irker.mdwn b/doc/plugins/contrib/irker.mdwn
new file mode 100644
index 0000000..bbc24e5
--- /dev/null
+++ b/doc/plugins/contrib/irker.mdwn
@@ -0,0 +1,128 @@
+[[!template id=plugin name=irker author="[[anarcat]]"]]
+[[!tag type/special-purpose]]
+
+This plugin will configure your wiki to send IRC notifications using the [irker](http://www.catb.org/esr/irker/) notification bot.
+
+It is fairly simple and requires no configuration but installation of the irker package. For template configuration, patches from [Debian bug #824512](https://bugs.debian.org/824512) are necessary.
+
+[[!format perl """
+package IkiWiki::Plugin::irker;
+
+use warnings;
+use strict;
+use IkiWiki 3.00;
+
+sub import {
+    hook(type => "getsetup", id => "irker", call => \&getsetup);
+    hook(type => "checkconfig", id => "branchable", call => \&checkconfig,
+         first => 1);
+    hook(type => "genwrapper", id => "irker", call => \&genwrapper,
+         last => 1);
+}
+
+sub getsetup() {
+	return
+		plugin => {
+			safe => 0,
+			rebuild => undef,
+			section => "core",
+		},
+		irker_channels => {
+			type => "string",
+			example => ['ircs://irc.example.com/example'],
+			description => "IRC channels to send notifications to",
+			safe => 1,
+			rebuild => 0,
+		},
+		irker_template => {
+			type => "string",
+			example => "'%(bold)s%(project)s:%(reset)s %(green)s%(author)s%(reset)s %(repo)s:%(yellow)s%(branch)s%(reset)s * %(bold)s%(rev)s%(reset)s / %(bold)s%(files)s%(reset)s: %(logmsg)s %(brown)s%(url)s%(reset)s",
+			description => "Template to use for messages. Only supported with patch from https://bugs.debian.org/824512",
+			safe => 1,
+			rebuild => 0,
+		},
+		irker_hook => {
+			type => "string",
+			example => "irkerhook-git",
+			description => 'Hook to setup for notifications, will look in $PATH if File::Which is available, otherwise use absolute path.',
+			safe => 1,
+			rebuild => 0,
+		},
+}
+
+sub checkconfig {
+    use URI; # ikiwiki Depends on it
+    foreach my $channel (@{$config{'irker_channels'}}) {
+        my $uri = URI->new( $channel );
+        # inspired by http://stackoverflow.com/a/2599378/1174784
+        # and http://stackoverflow.com/a/4953329/1174784
+        if (!$uri->scheme || $uri->path =~ m/^([#&]?[^\x07\x2C\s]{,200})/) {
+            error("$channel is not a valid IRC channel URI");
+        }
+    }
+    # check if hook exists
+    if (-x $config{irker_hook}) {
+        # shortcut: already configured
+        return;
+    }
+    eval q{use File::Which};
+    # check with which, i available
+    if (!$@) {
+        my $hook;
+        if (!defined $config{'irker_hook'}) {
+            $config{'irker_hook'} = 'irkerhook-git';
+        }
+        $hook = which($config{'irker_hook'});
+        if (defined $hook) {
+            $config{'irker_hook'} = $hook;
+        }
+        else {
+            error("irker hook '$config{irker_hook}' not found in PATH");
+        }
+    }
+    if (!-x $config{irker_hook}) {
+        error("irker hook '$config{irker_hook}' not executable");
+    }
+}
+
+# Parses git_wrapper to find out where the git repository is.
+# cargo-culted from branchable.pm
+sub find_git_repository {
+	if ($config{rcs} eq 'git' &&
+	    $config{git_wrapper}=~m!^(.*)/hooks/post-update$!) {
+		return $1;
+	}
+	else {
+		return undef;
+	}
+}
+
+# setup the hook symlink and git configuration
+sub genwrapper() {
+    my $repo=find_git_repository();
+    if (defined $repo && defined $config{'irker_channels'}) {
+        if (!-l $repo . '/hooks/post-receive') {
+            if (-e $repo . '/hooks/post-receive') {
+                error('post-receive hook exists and is not a symlink, failed to setup hook');
+            }
+            symlink($config{'irker_hook'}, $repo . '/hooks/post-receive') || error('failed to symlink: $!');
+        }
+        my $channels = join(",", @{$config{'irker_channels'}});
+        exec { 'git' } ('config', '-C', $repo, 'config', 'irker.channels', $channels);
+        exec { 'git' } ('config', '-C', $repo, 'config', 'irker.channels', $config{'wikiname'});
+        if ($config{'irker_template'}) {
+            exec { 'git' } ('config', '-C', $repo, 'config', 'irker.channels', $config{'irker_template'});
+        }
+    }
+    else {
+        exec { 'git' } ('config', '-C', $repo, 'config', '--remove-section', 'irker');
+        if (-l $repo . '/hooks/post-receive' && 
+            readlink($repo . '/hooks/post-receive') =~ m/irkerhook/) {
+            unlink($repo . '/hooks/post-receive');
+        }
+    }
+    return "";
+}
+
+1
+"""]]
diff --git a/doc/tips/monitor_page_changes_through_IRC.mdwn b/doc/tips/monitor_page_changes_through_IRC.mdwn
index b958b89..d1b6113 100644
--- a/doc/tips/monitor_page_changes_through_IRC.mdwn
+++ b/doc/tips/monitor_page_changes_through_IRC.mdwn
@@ -17,6 +17,6 @@ there are basically two alternatives now:
 * [KGB](https://kgb.alioth.debian.org/) - a Perl script that has been running at Debian since 2009
 * [irker](http://www.catb.org/esr/irker/) - a Python script whipped up by ESR in the fall of CIA.vc (~2011), ignoring the existing KGB bot
 
-KGB is harder to setup ([tutorial](https://www.donarmstrong.com/posts/switching_to_kgb/)), as it , but more reliable than irker, in my experience. --[[anarcat]]
+KGB is harder to setup ([tutorial](https://www.donarmstrong.com/posts/switching_to_kgb/)), as it , but more reliable than irker, in my experience. I built the [[plugins/contrib/irker]] plugin to automatically configure notifications with irker. --[[anarcat]]

(Diff truncated)
This reverts commit 855a7b5c6cabdd095253da8a3ff89f769d657b27
diff --git a/doc/bugs/Anon_edit_caused_lock_out_on_entire_site_.mdwn b/doc/bugs/Anon_edit_caused_lock_out_on_entire_site_.mdwn
index f4f2f26..a669413 100644
--- a/doc/bugs/Anon_edit_caused_lock_out_on_entire_site_.mdwn
+++ b/doc/bugs/Anon_edit_caused_lock_out_on_entire_site_.mdwn
@@ -26,10 +26,6 @@ The `moderatedcomments` plugins is **not** enabled
 
 The `anonok` plugin is **not** enabled
 
-> What are your complete `add_plugins` and `disable_plugins` options?
-> Which version of ikiwiki are you running? Are you using any third-party
-> plugins or patches? --[[smcv]]
-
 ---
 
 ## Steps
@@ -61,12 +57,3 @@ For [this particular installation](https://dev.iikb.xyz), that's not the case.
 ## Question
 
 Is there a session file or something to logout this phantom user?
-
-> See [[tips/inside_dot_ikiwiki]]. `.ikiwiki/userdb` is a Perl Storable file;
-> there are instructions for inspecting it on that page. `.ikiwiki/sessions.db`
-> is most likely a Berkeley DB file.
->
-> I would be interested to see the contents of these two files and the complete
-> `.setup` file. I would also be interested to see a tarball of the entire
-> wiki source directory, if it isn't excessively large. If you'd be willing to
-> share them, please contact <mailto:smcv@debian.org>. --[[smcv]]

This reverts commit 2d1615c340407cd21ba478449ea1444bb46432ca
diff --git a/doc/bugs/password_reset_failure.mdwn b/doc/bugs/password_reset_failure.mdwn
deleted file mode 100644
index 1e40981..0000000
--- a/doc/bugs/password_reset_failure.mdwn
+++ /dev/null
@@ -1,22 +0,0 @@
-I can't seem to do a password reset on this wiki. I am writing this
-through the anonymous git push interface (phew for that!).
-
-I have tried three times now to reset my password through the user
-interface - my account name is [[anarcat]], and when i do the password
-reset, I get a token. I go visit the website, set a passphrase, click
-`Save Preferences` and I end up on a login form. I enter my
-passphrase, click `Login` and I get the error:
-
-    1 error(s) were encountered with your submission. Please correct the fields highlighted below.
-    
-    Name
-    [anarcat]
-    
-    Password
-    [*************] Invalid entry
-
-`Password` is highlighted.
-
-Even if I leave the password there (my cleartext password is in the
-login form by default after the password reset, which is strange), it
-still gives me that error. -- [[anarcat]]

This reverts commit 01eeb89d59cc3d88712f6559acdaa51328756729
diff --git a/doc/plugins/contrib/irker.mdwn b/doc/plugins/contrib/irker.mdwn
deleted file mode 100644
index bbc24e5..0000000
--- a/doc/plugins/contrib/irker.mdwn
+++ /dev/null
@@ -1,128 +0,0 @@
-[[!template id=plugin name=irker author="[[anarcat]]"]]
-[[!tag type/special-purpose]]
-
-This plugin will configure your wiki to send IRC notifications using the [irker](http://www.catb.org/esr/irker/) notification bot.
-
-It is fairly simple and requires no configuration but installation of the irker package. For template configuration, patches from [Debian bug #824512](https://bugs.debian.org/824512) are necessary.
-
-[[!format perl """
-package IkiWiki::Plugin::irker;
-
-use warnings;
-use strict;
-use IkiWiki 3.00;
-
-sub import {
-    hook(type => "getsetup", id => "irker", call => \&getsetup);
-    hook(type => "checkconfig", id => "branchable", call => \&checkconfig,
-         first => 1);
-    hook(type => "genwrapper", id => "irker", call => \&genwrapper,
-         last => 1);
-}
-
-sub getsetup() {
-	return
-		plugin => {
-			safe => 0,
-			rebuild => undef,
-			section => "core",
-		},
-		irker_channels => {
-			type => "string",
-			example => ['ircs://irc.example.com/example'],
-			description => "IRC channels to send notifications to",
-			safe => 1,
-			rebuild => 0,
-		},
-		irker_template => {
-			type => "string",
-			example => "'%(bold)s%(project)s:%(reset)s %(green)s%(author)s%(reset)s %(repo)s:%(yellow)s%(branch)s%(reset)s * %(bold)s%(rev)s%(reset)s / %(bold)s%(files)s%(reset)s: %(logmsg)s %(brown)s%(url)s%(reset)s",
-			description => "Template to use for messages. Only supported with patch from https://bugs.debian.org/824512",
-			safe => 1,
-			rebuild => 0,
-		},
-		irker_hook => {
-			type => "string",
-			example => "irkerhook-git",
-			description => 'Hook to setup for notifications, will look in $PATH if File::Which is available, otherwise use absolute path.',
-			safe => 1,
-			rebuild => 0,
-		},
-}
-
-sub checkconfig {
-    use URI; # ikiwiki Depends on it
-    foreach my $channel (@{$config{'irker_channels'}}) {
-        my $uri = URI->new( $channel );
-        # inspired by http://stackoverflow.com/a/2599378/1174784
-        # and http://stackoverflow.com/a/4953329/1174784
-        if (!$uri->scheme || $uri->path =~ m/^([#&]?[^\x07\x2C\s]{,200})/) {
-            error("$channel is not a valid IRC channel URI");
-        }
-    }
-    # check if hook exists
-    if (-x $config{irker_hook}) {
-        # shortcut: already configured
-        return;
-    }
-    eval q{use File::Which};
-    # check with which, i available
-    if (!$@) {
-        my $hook;
-        if (!defined $config{'irker_hook'}) {
-            $config{'irker_hook'} = 'irkerhook-git';
-        }
-        $hook = which($config{'irker_hook'});
-        if (defined $hook) {
-            $config{'irker_hook'} = $hook;
-        }
-        else {
-            error("irker hook '$config{irker_hook}' not found in PATH");
-        }
-    }
-    if (!-x $config{irker_hook}) {
-        error("irker hook '$config{irker_hook}' not executable");
-    }
-}
-
-# Parses git_wrapper to find out where the git repository is.
-# cargo-culted from branchable.pm
-sub find_git_repository {
-	if ($config{rcs} eq 'git' &&
-	    $config{git_wrapper}=~m!^(.*)/hooks/post-update$!) {
-		return $1;
-	}
-	else {
-		return undef;
-	}
-}
-
-# setup the hook symlink and git configuration
-sub genwrapper() {
-    my $repo=find_git_repository();
-    if (defined $repo && defined $config{'irker_channels'}) {
-        if (!-l $repo . '/hooks/post-receive') {
-            if (-e $repo . '/hooks/post-receive') {
-                error('post-receive hook exists and is not a symlink, failed to setup hook');
-            }
-            symlink($config{'irker_hook'}, $repo . '/hooks/post-receive') || error('failed to symlink: $!');
-        }
-        my $channels = join(",", @{$config{'irker_channels'}});
-        exec { 'git' } ('config', '-C', $repo, 'config', 'irker.channels', $channels);
-        exec { 'git' } ('config', '-C', $repo, 'config', 'irker.channels', $config{'wikiname'});
-        if ($config{'irker_template'}) {
-            exec { 'git' } ('config', '-C', $repo, 'config', 'irker.channels', $config{'irker_template'});
-        }
-    }
-    else {
-        exec { 'git' } ('config', '-C', $repo, 'config', '--remove-section', 'irker');
-        if (-l $repo . '/hooks/post-receive' && 
-            readlink($repo . '/hooks/post-receive') =~ m/irkerhook/) {
-            unlink($repo . '/hooks/post-receive');
-        }
-    }
-    return "";
-}
-
-1
-"""]]

This reverts commit bda4eba674ee46289cccaf8e89ee9edde1dcba1e
diff --git a/doc/tips/monitor_page_changes_through_IRC.mdwn b/doc/tips/monitor_page_changes_through_IRC.mdwn
index d1b6113..b958b89 100644
--- a/doc/tips/monitor_page_changes_through_IRC.mdwn
+++ b/doc/tips/monitor_page_changes_through_IRC.mdwn
@@ -17,6 +17,6 @@ there are basically two alternatives now:
 * [KGB](https://kgb.alioth.debian.org/) - a Perl script that has been running at Debian since 2009
 * [irker](http://www.catb.org/esr/irker/) - a Python script whipped up by ESR in the fall of CIA.vc (~2011), ignoring the existing KGB bot
 
-KGB is harder to setup ([tutorial](https://www.donarmstrong.com/posts/switching_to_kgb/)), as it , but more reliable than irker, in my experience. I built the [[plugins/contrib/irker]] plugin to automatically configure notifications with irker. --[[anarcat]]
+KGB is harder to setup ([tutorial](https://www.donarmstrong.com/posts/switching_to_kgb/)), as it , but more reliable than irker, in my experience. --[[anarcat]]
 
 See also [[todo/ikibot]] for another bot idea.

and we have a bot
diff --git a/doc/tips/monitor_page_changes_through_IRC.mdwn b/doc/tips/monitor_page_changes_through_IRC.mdwn
index b958b89..d1b6113 100644
--- a/doc/tips/monitor_page_changes_through_IRC.mdwn
+++ b/doc/tips/monitor_page_changes_through_IRC.mdwn
@@ -17,6 +17,6 @@ there are basically two alternatives now:
 * [KGB](https://kgb.alioth.debian.org/) - a Perl script that has been running at Debian since 2009
 * [irker](http://www.catb.org/esr/irker/) - a Python script whipped up by ESR in the fall of CIA.vc (~2011), ignoring the existing KGB bot
 
-KGB is harder to setup ([tutorial](https://www.donarmstrong.com/posts/switching_to_kgb/)), as it , but more reliable than irker, in my experience. --[[anarcat]]
+KGB is harder to setup ([tutorial](https://www.donarmstrong.com/posts/switching_to_kgb/)), as it , but more reliable than irker, in my experience. I built the [[plugins/contrib/irker]] plugin to automatically configure notifications with irker. --[[anarcat]]
 
 See also [[todo/ikibot]] for another bot idea.

little irc integration plugin
diff --git a/doc/plugins/contrib/irker.mdwn b/doc/plugins/contrib/irker.mdwn
new file mode 100644
index 0000000..bbc24e5
--- /dev/null
+++ b/doc/plugins/contrib/irker.mdwn
@@ -0,0 +1,128 @@
+[[!template id=plugin name=irker author="[[anarcat]]"]]
+[[!tag type/special-purpose]]
+
+This plugin will configure your wiki to send IRC notifications using the [irker](http://www.catb.org/esr/irker/) notification bot.
+
+It is fairly simple and requires no configuration but installation of the irker package. For template configuration, patches from [Debian bug #824512](https://bugs.debian.org/824512) are necessary.
+
+[[!format perl """
+package IkiWiki::Plugin::irker;
+
+use warnings;
+use strict;
+use IkiWiki 3.00;
+
+sub import {
+    hook(type => "getsetup", id => "irker", call => \&getsetup);
+    hook(type => "checkconfig", id => "branchable", call => \&checkconfig,
+         first => 1);
+    hook(type => "genwrapper", id => "irker", call => \&genwrapper,
+         last => 1);
+}
+
+sub getsetup() {
+	return
+		plugin => {
+			safe => 0,
+			rebuild => undef,
+			section => "core",
+		},
+		irker_channels => {
+			type => "string",
+			example => ['ircs://irc.example.com/example'],
+			description => "IRC channels to send notifications to",
+			safe => 1,
+			rebuild => 0,
+		},
+		irker_template => {
+			type => "string",
+			example => "'%(bold)s%(project)s:%(reset)s %(green)s%(author)s%(reset)s %(repo)s:%(yellow)s%(branch)s%(reset)s * %(bold)s%(rev)s%(reset)s / %(bold)s%(files)s%(reset)s: %(logmsg)s %(brown)s%(url)s%(reset)s",
+			description => "Template to use for messages. Only supported with patch from https://bugs.debian.org/824512",
+			safe => 1,
+			rebuild => 0,
+		},
+		irker_hook => {
+			type => "string",
+			example => "irkerhook-git",
+			description => 'Hook to setup for notifications, will look in $PATH if File::Which is available, otherwise use absolute path.',
+			safe => 1,
+			rebuild => 0,
+		},
+}
+
+sub checkconfig {
+    use URI; # ikiwiki Depends on it
+    foreach my $channel (@{$config{'irker_channels'}}) {
+        my $uri = URI->new( $channel );
+        # inspired by http://stackoverflow.com/a/2599378/1174784
+        # and http://stackoverflow.com/a/4953329/1174784
+        if (!$uri->scheme || $uri->path =~ m/^([#&]?[^\x07\x2C\s]{,200})/) {
+            error("$channel is not a valid IRC channel URI");
+        }
+    }
+    # check if hook exists
+    if (-x $config{irker_hook}) {
+        # shortcut: already configured
+        return;
+    }
+    eval q{use File::Which};
+    # check with which, i available
+    if (!$@) {
+        my $hook;
+        if (!defined $config{'irker_hook'}) {
+            $config{'irker_hook'} = 'irkerhook-git';
+        }
+        $hook = which($config{'irker_hook'});
+        if (defined $hook) {
+            $config{'irker_hook'} = $hook;
+        }
+        else {
+            error("irker hook '$config{irker_hook}' not found in PATH");
+        }
+    }
+    if (!-x $config{irker_hook}) {
+        error("irker hook '$config{irker_hook}' not executable");
+    }
+}
+
+# Parses git_wrapper to find out where the git repository is.
+# cargo-culted from branchable.pm
+sub find_git_repository {
+	if ($config{rcs} eq 'git' &&
+	    $config{git_wrapper}=~m!^(.*)/hooks/post-update$!) {
+		return $1;
+	}
+	else {
+		return undef;
+	}
+}
+
+# setup the hook symlink and git configuration
+sub genwrapper() {
+    my $repo=find_git_repository();
+    if (defined $repo && defined $config{'irker_channels'}) {
+        if (!-l $repo . '/hooks/post-receive') {
+            if (-e $repo . '/hooks/post-receive') {
+                error('post-receive hook exists and is not a symlink, failed to setup hook');
+            }
+            symlink($config{'irker_hook'}, $repo . '/hooks/post-receive') || error('failed to symlink: $!');
+        }
+        my $channels = join(",", @{$config{'irker_channels'}});
+        exec { 'git' } ('config', '-C', $repo, 'config', 'irker.channels', $channels);
+        exec { 'git' } ('config', '-C', $repo, 'config', 'irker.channels', $config{'wikiname'});
+        if ($config{'irker_template'}) {
+            exec { 'git' } ('config', '-C', $repo, 'config', 'irker.channels', $config{'irker_template'});
+        }
+    }
+    else {
+        exec { 'git' } ('config', '-C', $repo, 'config', '--remove-section', 'irker');
+        if (-l $repo . '/hooks/post-receive' && 
+            readlink($repo . '/hooks/post-receive') =~ m/irkerhook/) {
+            unlink($repo . '/hooks/post-receive');
+        }
+    }
+    return "";
+}
+
+1
+"""]]

add details on bot setup
diff --git a/doc/tips/monitor_page_changes_through_IRC.mdwn b/doc/tips/monitor_page_changes_through_IRC.mdwn
index 3c5d17e..b958b89 100644
--- a/doc/tips/monitor_page_changes_through_IRC.mdwn
+++ b/doc/tips/monitor_page_changes_through_IRC.mdwn
@@ -9,3 +9,14 @@ the workaround I found so far was to join the `#ikiwiki` channel on freenode, an
 this will watch for any change to this page. -- [[anarcat]]
 
 hello anarcat, I'm editing your page! -- [[micah]]
+
+obviously, the above assumes that the wiki is already configured to send notifications on IRC when commits are done through the git repository. there are multiple ways of doing that, which somewhat fall outside the scope of Ikiwiki itself, since you should really learn how to do this elsewhere. All you need to know is that the hook needs to be in `repository.git/hooks/post-receive` file.
+
+there are basically two alternatives now:
+
+* [KGB](https://kgb.alioth.debian.org/) - a Perl script that has been running at Debian since 2009
+* [irker](http://www.catb.org/esr/irker/) - a Python script whipped up by ESR in the fall of CIA.vc (~2011), ignoring the existing KGB bot
+
+KGB is harder to setup ([tutorial](https://www.donarmstrong.com/posts/switching_to_kgb/)), as it , but more reliable than irker, in my experience. --[[anarcat]]
+
+See also [[todo/ikibot]] for another bot idea.

mention that the CVE-2016-4561 fix was backported
diff --git a/doc/security.mdwn b/doc/security.mdwn
index 594b721..055e1d0 100644
--- a/doc/security.mdwn
+++ b/doc/security.mdwn
@@ -514,12 +514,17 @@ CGI error messages did not escape HTML meta-characters, potentially
 allowing an attacker to carry out cross-site scripting by directing a
 user to a URL that would result in a crafted ikiwiki error message. This
 was discovered on 4 May by the ikiwiki developers, and the fixed version
-3.20160506 was released on 6 May. An upgrade is recommended for sites using
+3.20160506 was released on 6 May. The same fixes were backported to Debian
+8 "jessie" in version 3.20141016.3. A backport to Debian 7 "wheezy" is
+in progress.
+
+An upgrade is recommended for sites using
 the CGI. ([[!cve CVE-2016-4561]], OVE-20160505-0012)
 
 ## ImageMagick CVE-2016–3714 ("ImageTragick")
 
-ikiwiki 3.20160506 attempts to mitigate [[!cve CVE-2016-3714]] and any
+ikiwiki 3.20160506 and 3.20141016.3 attempt to mitigate
+[[!cve CVE-2016-3714]], and any
 future ImageMagick vulnerabilities that resemble it, by restricting the
 image formats that the [[ikiwiki/directive/img]] directive is willing to
 resize. An upgrade is recommended for sites where an untrusted user is

Clarifying
diff --git a/doc/todo/merge_bootstrap_branch.mdwn b/doc/todo/merge_bootstrap_branch.mdwn
index e2fb5f3..34a4a1f 100644
--- a/doc/todo/merge_bootstrap_branch.mdwn
+++ b/doc/todo/merge_bootstrap_branch.mdwn
@@ -25,6 +25,7 @@ except when the bootstrap theme is enabled.
 >> As for not tampering with template files, the only way I found to
 >> work around this is to rename the desired bootstrap classes to the
 >> ones that the default ikiwiki template wants (toc, map, etc.).
->> [see for yourself](https://notabug.org/iikb/ikiwiki-theme-bootstrap/commit/7f30630b6255336a34b14f70f2a674e15cd797a0) - don't mind the red parts.
+>> What this means is copying css code from `bootstrap.css` to the `styles.css`.
+>> [See for yourself](https://notabug.org/iikb/ikiwiki-theme-bootstrap/commit/7f30630b6255336a34b14f70f2a674e15cd797a0) - don't mind the red parts.
 >> This is tedious and boring, it's easier to tamper with template files
 >> than to rewrite bootstrap by copying and pasting it. --[[desci]]

Adding info regarding bootstrap classes
diff --git a/doc/todo/merge_bootstrap_branch.mdwn b/doc/todo/merge_bootstrap_branch.mdwn
index ee42bf5..e2fb5f3 100644
--- a/doc/todo/merge_bootstrap_branch.mdwn
+++ b/doc/todo/merge_bootstrap_branch.mdwn
@@ -21,3 +21,10 @@ except when the bootstrap theme is enabled.
 >
 > My work on bootstrap also involved some changes to the base templates,
 > not sure there is a way to work around that. --[[anarcat]]
+
+>> As for not tampering with template files, the only way I found to
+>> work around this is to rename the desired bootstrap classes to the
+>> ones that the default ikiwiki template wants (toc, map, etc.).
+>> [see for yourself](https://notabug.org/iikb/ikiwiki-theme-bootstrap/commit/7f30630b6255336a34b14f70f2a674e15cd797a0) - don't mind the red parts.
+>> This is tedious and boring, it's easier to tamper with template files
+>> than to rewrite bootstrap by copying and pasting it. --[[desci]]

Adding sites
diff --git a/doc/users/desci.mdwn b/doc/users/desci.mdwn
index dce4ea4..e2ebefd 100644
--- a/doc/users/desci.mdwn
+++ b/doc/users/desci.mdwn
@@ -1,24 +1,25 @@
-# Personal information
+## Personal information
 
 <https://desci.xyz>
 
 ---
 
-# Ikiwiki Plugins
+## Ikiwiki Plugins
 
 A plugin to add facebook spyware to your ikiwiki: [[plugins/contrib/opengraph/]]
 
 ---
 
-# Ikiwiki Themes
+## Ikiwiki Themes
 
 A theme to add [bootstrap 3](https://getbootstrap.com) to ikiwiki without overhauling the installation: [[forum/bootstrap_theme]]
 
 ---
 
-# Ikiwiki Sites
+## Ikiwiki Sites
 
-## Currently online:
+### Currently online:
 
-* <https://dev.iikb.org>
-* <https://dev.iikb.xyz> (proxy_pass)
+* <https://iikb.org> - <https://iikb.xyz> (alternative domain)
+* <https://piratas.xyz> - <https://partidopirata.xyz> (alternative domain)
+* <https://sul.partidopirata.xyz>

thanks!
diff --git a/doc/bugs/tag_missing_for_3.20141016.3.mdwn b/doc/bugs/tag_missing_for_3.20141016.3.mdwn
index bc67268..3e3c879 100644
--- a/doc/bugs/tag_missing_for_3.20141016.3.mdwn
+++ b/doc/bugs/tag_missing_for_3.20141016.3.mdwn
@@ -5,3 +5,8 @@ There is no tag for the Debian release numbered: 3.20141016.3. it *seems* like i
 > different suites since Friday, three of which need someone else's
 > approval before they're finalized, so please excuse delays to the
 > peripheral stuff like tags and release notes. --[[smcv]]
+
+> > Hey, no problem at all. :) Thanks so much for taking care of all this
+> > it is much appreciated. I didn't mean to put pressure at all here,
+> > I just thought it was forgotten. Sorry if it was misunderstood! 
+> > --[[anarcat]]

tag added
diff --git a/doc/bugs/tag_missing_for_3.20141016.3.mdwn b/doc/bugs/tag_missing_for_3.20141016.3.mdwn
index 5c71f51..bc67268 100644
--- a/doc/bugs/tag_missing_for_3.20141016.3.mdwn
+++ b/doc/bugs/tag_missing_for_3.20141016.3.mdwn
@@ -1 +1,7 @@
 There is no tag for the Debian release numbered: 3.20141016.3. it *seems* like it should be the head of the debian-jessie branch (51b4083). I can't seem to push the tag myself. --[[anarcat]]
+
+> [[Now pushed|done]]. I didn't want to tag 3.20141016.3 while there was a chance
+> that I'd have to redo it. So far I've prepared four security releases for
+> different suites since Friday, three of which need someone else's
+> approval before they're finalized, so please excuse delays to the
+> peripheral stuff like tags and release notes. --[[smcv]]

thanks!
diff --git a/doc/todo/git-annex_support.mdwn b/doc/todo/git-annex_support.mdwn
index 6659714..c49cab4 100644
--- a/doc/todo/git-annex_support.mdwn
+++ b/doc/todo/git-annex_support.mdwn
@@ -238,3 +238,7 @@ This [[patch]] still applies - anything else I should be doing here to try to ge
 > queue, but at right now I'm still trying to deal with mitigating
 > CVE-2016-3714, and the last thing I want to do is merge new security
 > risks. --[[smcv]]
+
+> > No problem at all, glad that you still have that in the queue, and I hope
+> > my work was somewhat useful in pushing this forward! Thanks for taking
+> > care of the Imagetragick situation... :/ --[[anarcat]]

sorry, one day I'll review this, but this is not that day
diff --git a/doc/todo/git-annex_support.mdwn b/doc/todo/git-annex_support.mdwn
index b2828c9..6659714 100644
--- a/doc/todo/git-annex_support.mdwn
+++ b/doc/todo/git-annex_support.mdwn
@@ -231,3 +231,10 @@ add_plugins:
 > <del>...aaaand this doesn't work anymore. :( i could have sworn this was working minutes ago, but for some reason the annexed files get skipped again now. :(</del> Sorry for the noise, the annex repo wasn't in direct mode - the above works! --[[anarcat]]
 
 This [[patch]] still applies - anything else I should be doing here to try to get this fixed? A summary maybe? --[[anarcat]]
+
+> Sorry, I don't have the mental bandwidth at the moment to work through the
+> implications of this change. I know you want this feature, I know it's an
+> attractive solution to several use cases, and git annex support is in the
+> queue, but at right now I'm still trying to deal with mitigating
+> CVE-2016-3714, and the last thing I want to do is merge new security
+> risks. --[[smcv]]

still using this in production, would welcome feedback
diff --git a/doc/todo/git-annex_support.mdwn b/doc/todo/git-annex_support.mdwn
index 342319c..b2828c9 100644
--- a/doc/todo/git-annex_support.mdwn
+++ b/doc/todo/git-annex_support.mdwn
@@ -229,3 +229,5 @@ add_plugins:
 ... and the `ikiwiki-hosting` patch mentionned earlier to allow git-annex-shell to run at all. Also, the `--shared` option will [make git-annex use hardlinks itself between the two repos](https://git-annex.branchable.com/todo/wishlist:_use_hardlinks_for_local_clones/), so the files will be available for download as well. --[[anarcat]]
 
 > <del>...aaaand this doesn't work anymore. :( i could have sworn this was working minutes ago, but for some reason the annexed files get skipped again now. :(</del> Sorry for the noise, the annex repo wasn't in direct mode - the above works! --[[anarcat]]
+
+This [[patch]] still applies - anything else I should be doing here to try to get this fixed? A summary maybe? --[[anarcat]]

dropping this.
diff --git a/doc/bugs/notifyemail_fails_with_some_openid_providers.mdwn b/doc/bugs/notifyemail_fails_with_some_openid_providers.mdwn
index 48b046b..c0610af 100644
--- a/doc/bugs/notifyemail_fails_with_some_openid_providers.mdwn
+++ b/doc/bugs/notifyemail_fails_with_some_openid_providers.mdwn
@@ -109,3 +109,5 @@ Any other ideas? --[[anarcat]]
 >>>>>> But the problem is that is a separate feature request, which should be filed as a
 >>>>>> separate [[wishlist]] item. What I am describing above is an actual *bug* that should be fixed regardless of
 >>>>>> the color you want that poney to be. :p -- [[anarcat]]
+
+Considering the doom and death surrounding OpenID these days, I think I'll just give up on this patch for now, especially given how little acceptance it has found here. So [[done]]. --[[anarcat]]

diff --git a/doc/bugs/tag_missing_for_3.20141016.3.mdwn b/doc/bugs/tag_missing_for_3.20141016.3.mdwn
new file mode 100644
index 0000000..5c71f51
--- /dev/null
+++ b/doc/bugs/tag_missing_for_3.20141016.3.mdwn
@@ -0,0 +1 @@
+There is no tag for the Debian release numbered: 3.20141016.3. it *seems* like it should be the head of the debian-jessie branch (51b4083). I can't seem to push the tag myself. --[[anarcat]]

Add CVE reference
diff --git a/doc/news/version_3.20160506.mdwn b/doc/news/version_3.20160506.mdwn
index 331a48b..6800a30 100644
--- a/doc/news/version_3.20160506.mdwn
+++ b/doc/news/version_3.20160506.mdwn
@@ -22,7 +22,7 @@ ikiwiki 3.20160506 released with [[!toggle text="these changes"]]
 [[!toggleable text="""
  * [ [[Simon McVittie|smcv]] ]
    * HTML-escape error messages, in one case avoiding potential cross-site
-     scripting (OVE-20160505-0012)
+     scripting ([[!cve CVE-2016-4561]], OVE-20160505-0012)
    * Mitigate ImageMagick vulnerabilities such as CVE-2016-3714:
      - img: force common Web formats to be interpreted according to extension,
        so that "allowed\_attachments: '*.jpg'" does what one might expect
diff --git a/doc/security.mdwn b/doc/security.mdwn
index 6d4841f..594b721 100644
--- a/doc/security.mdwn
+++ b/doc/security.mdwn
@@ -515,7 +515,7 @@ allowing an attacker to carry out cross-site scripting by directing a
 user to a URL that would result in a crafted ikiwiki error message. This
 was discovered on 4 May by the ikiwiki developers, and the fixed version
 3.20160506 was released on 6 May. An upgrade is recommended for sites using
-the CGI.
+the CGI. ([[!cve CVE-2016-4561]], OVE-20160505-0012)
 
 ## ImageMagick CVE-2016–3714 ("ImageTragick")
 

respond
diff --git a/doc/bugs/Anon_edit_caused_lock_out_on_entire_site_.mdwn b/doc/bugs/Anon_edit_caused_lock_out_on_entire_site_.mdwn
index a669413..f4f2f26 100644
--- a/doc/bugs/Anon_edit_caused_lock_out_on_entire_site_.mdwn
+++ b/doc/bugs/Anon_edit_caused_lock_out_on_entire_site_.mdwn
@@ -26,6 +26,10 @@ The `moderatedcomments` plugins is **not** enabled
 
 The `anonok` plugin is **not** enabled
 
+> What are your complete `add_plugins` and `disable_plugins` options?
+> Which version of ikiwiki are you running? Are you using any third-party
+> plugins or patches? --[[smcv]]
+
 ---
 
 ## Steps
@@ -57,3 +61,12 @@ For [this particular installation](https://dev.iikb.xyz), that's not the case.
 ## Question
 
 Is there a session file or something to logout this phantom user?
+
+> See [[tips/inside_dot_ikiwiki]]. `.ikiwiki/userdb` is a Perl Storable file;
+> there are instructions for inspecting it on that page. `.ikiwiki/sessions.db`
+> is most likely a Berkeley DB file.
+>
+> I would be interested to see the contents of these two files and the complete
+> `.setup` file. I would also be interested to see a tarball of the entire
+> wiki source directory, if it isn't excessively large. If you'd be willing to
+> share them, please contact <mailto:smcv@debian.org>. --[[smcv]]

use intended filename
diff --git a/doc/bugs/Correctly_handle_filenames_starting_with_a_dash_in_add/rm/mv.mdwn b/doc/bugs/Correctly_handle_filenames_starting_with_a_dash_in_add/rm/mv.mdwn
deleted file mode 100644
index abe704f..0000000
--- a/doc/bugs/Correctly_handle_filenames_starting_with_a_dash_in_add/rm/mv.mdwn
+++ /dev/null
@@ -1,3 +0,0 @@
-BUG: Creating pages starting with dash(es) in the CGI doesn't add/commit them automatically to the GIT backend repository. This is fixed in the forked repository at <https://github.com/wagnerflo/ikiwiki> in commit [6b0ae40](https://github.com/wagnerflo/ikiwiki/commit/6b0ae40d109c58ae5ca098496ac30c7ef0074131).
-
-> Joey merged your patch back in March, and it is in today's release. [[done]] --[[smcv]]
diff --git a/doc/bugs/Correctly_handle_filenames_starting_with_a_dash_in_add__47__rm__47__mv.mdwn b/doc/bugs/Correctly_handle_filenames_starting_with_a_dash_in_add__47__rm__47__mv.mdwn
new file mode 100644
index 0000000..abe704f
--- /dev/null
+++ b/doc/bugs/Correctly_handle_filenames_starting_with_a_dash_in_add__47__rm__47__mv.mdwn
@@ -0,0 +1,3 @@
+BUG: Creating pages starting with dash(es) in the CGI doesn't add/commit them automatically to the GIT backend repository. This is fixed in the forked repository at <https://github.com/wagnerflo/ikiwiki> in commit [6b0ae40](https://github.com/wagnerflo/ikiwiki/commit/6b0ae40d109c58ae5ca098496ac30c7ef0074131).
+
+> Joey merged your patch back in March, and it is in today's release. [[done]] --[[smcv]]

escape directive properly; add paragraph breaks
diff --git a/doc/news/version_3.20160506.mdwn b/doc/news/version_3.20160506.mdwn
index 650588c..331a48b 100644
--- a/doc/news/version_3.20160506.mdwn
+++ b/doc/news/version_3.20160506.mdwn
@@ -1,15 +1,19 @@
 News for ikiwiki 3.20160506:
 
    To mitigate [[!cve CVE-2016-3714]] and similar ImageMagick security vulnerabilities,
-   the `[[!img]]` directive is now restricted to these common web formats by
+   the `\[[!img]]` directive is now restricted to these common web formats by
    default:
+
    * JPEG (`.jpg`, `.jpeg`)
    * PNG (`.png`)
    * GIF (`.gif`)
    * SVG (`.svg`)
+
    (In particular, by default resizing PDF files is no longer allowed.)
+
    Additionally, resized SVG files are displayed in the browser as SVG
    instead of being converted to PNG.
+
    If all users who can attach images are fully trusted, this restriction
    can be removed with the new img\_allowed\_formats setup option.
    See [[ikiwiki/directive/img]] for more details.

rename todo/Correctly_handle_filenames_starting_with_a_dash_in_add__47__rm__47__mv.mdwn to bugs/Correctly_handle_filenames_starting_with_a_dash_in_add/rm/mv.mdwn
diff --git a/doc/bugs/Correctly_handle_filenames_starting_with_a_dash_in_add/rm/mv.mdwn b/doc/bugs/Correctly_handle_filenames_starting_with_a_dash_in_add/rm/mv.mdwn
new file mode 100644
index 0000000..abe704f
--- /dev/null
+++ b/doc/bugs/Correctly_handle_filenames_starting_with_a_dash_in_add/rm/mv.mdwn
@@ -0,0 +1,3 @@
+BUG: Creating pages starting with dash(es) in the CGI doesn't add/commit them automatically to the GIT backend repository. This is fixed in the forked repository at <https://github.com/wagnerflo/ikiwiki> in commit [6b0ae40](https://github.com/wagnerflo/ikiwiki/commit/6b0ae40d109c58ae5ca098496ac30c7ef0074131).
+
+> Joey merged your patch back in March, and it is in today's release. [[done]] --[[smcv]]
diff --git a/doc/todo/Correctly_handle_filenames_starting_with_a_dash_in_add__47__rm__47__mv.mdwn b/doc/todo/Correctly_handle_filenames_starting_with_a_dash_in_add__47__rm__47__mv.mdwn
deleted file mode 100644
index abe704f..0000000
--- a/doc/todo/Correctly_handle_filenames_starting_with_a_dash_in_add__47__rm__47__mv.mdwn
+++ /dev/null
@@ -1,3 +0,0 @@
-BUG: Creating pages starting with dash(es) in the CGI doesn't add/commit them automatically to the GIT backend repository. This is fixed in the forked repository at <https://github.com/wagnerflo/ikiwiki> in commit [6b0ae40](https://github.com/wagnerflo/ikiwiki/commit/6b0ae40d109c58ae5ca098496ac30c7ef0074131).
-
-> Joey merged your patch back in March, and it is in today's release. [[done]] --[[smcv]]

already fixed
diff --git a/doc/todo/Correctly_handle_filenames_starting_with_a_dash_in_add__47__rm__47__mv.mdwn b/doc/todo/Correctly_handle_filenames_starting_with_a_dash_in_add__47__rm__47__mv.mdwn
index 5a34035..abe704f 100644
--- a/doc/todo/Correctly_handle_filenames_starting_with_a_dash_in_add__47__rm__47__mv.mdwn
+++ b/doc/todo/Correctly_handle_filenames_starting_with_a_dash_in_add__47__rm__47__mv.mdwn
@@ -1 +1,3 @@
 BUG: Creating pages starting with dash(es) in the CGI doesn't add/commit them automatically to the GIT backend repository. This is fixed in the forked repository at <https://github.com/wagnerflo/ikiwiki> in commit [6b0ae40](https://github.com/wagnerflo/ikiwiki/commit/6b0ae40d109c58ae5ca098496ac30c7ef0074131).
+
+> Joey merged your patch back in March, and it is in today's release. [[done]] --[[smcv]]

Announce 3.20160506
diff --git a/doc/news/version_3.20150107.mdwn b/doc/news/version_3.20150107.mdwn
deleted file mode 100644
index 7cae042..0000000
--- a/doc/news/version_3.20150107.mdwn
+++ /dev/null
@@ -1,44 +0,0 @@
-ikiwiki 3.20150107 released with [[!toggle text="these changes"]]
-[[!toggleable text="""
-  [ [[Joey Hess|joey]] ]
-
-  * Added ikiwiki-comment program.
-  * Add missing build-depends on `libcgi-formbuilder-perl`, needed for
-    `t/relativity.t`
-  * openid: Stop suppressing the email field on the Preferences page.
-  * Set Debian package maintainer to Simon McVittie as I'm retiring from
-    Debian.
-
-  [ [[Simon McVittie|smcv]] ]
-
-  * calendar: add `calendar_autocreate` option, with which `ikiwiki --refresh`
-    can mostly supersede the `ikiwiki-calendar` command.
-    Thanks, Louis Paternault
-  * search: add more classes as a hook for CSS. Thanks, sajolida
-  * core: generate HTML5 by default, but keep avoiding new elements
-    like `<section>` that require specific browser support unless `html5` is
-    set to 1.
-  * Tell mobile browsers to draw our pages in a device-sized viewport,
-    not an 800-1000px viewport designed to emulate a desktop/laptop browser.
-  * Add new `responsive_layout` option which can be set to 0 if your custom
-    CSS only works in a large viewport.
-  * style.css, actiontabs, blueview, goldtype, monochrome: adjust layout
-    below 600px ("responsive layout") so that horizontal scrolling is not
-    needed on smartphone browsers or other small viewports.
-  * core: new `libdirs` option alongside `libdir`. Thanks, Louis Paternault
-
-  [ [[Amitai Schlair|schmonz]] ]
-
-  * core: log a debug message before waiting for the lock.
-    Thanks, Mark Jason Dominus
-  * build: in po/Makefile, use the same `$(MAKE)` as the rest of the build.
-    Thanks, ttw
-  * blogspam: use the 2.0 JSON API (the 1.0 XML-RPC API has been EOL'd).
-    Closes: [[!debbug 774441]]
-
-  [ [[Joey Hess|joey]] ]
-
-  * po: If msgmerge falls over on a problem po file, print a warning
-    message, but don't let this problem crash ikiwiki entirely.
-"""]]
-[[!meta date="2015-01-07 10:24:25 +0000"]]
diff --git a/doc/news/version_3.20160506.mdwn b/doc/news/version_3.20160506.mdwn
new file mode 100644
index 0000000..650588c
--- /dev/null
+++ b/doc/news/version_3.20160506.mdwn
@@ -0,0 +1,45 @@
+News for ikiwiki 3.20160506:
+
+   To mitigate [[!cve CVE-2016-3714]] and similar ImageMagick security vulnerabilities,
+   the `[[!img]]` directive is now restricted to these common web formats by
+   default:
+   * JPEG (`.jpg`, `.jpeg`)
+   * PNG (`.png`)
+   * GIF (`.gif`)
+   * SVG (`.svg`)
+   (In particular, by default resizing PDF files is no longer allowed.)
+   Additionally, resized SVG files are displayed in the browser as SVG
+   instead of being converted to PNG.
+   If all users who can attach images are fully trusted, this restriction
+   can be removed with the new img\_allowed\_formats setup option.
+   See [[ikiwiki/directive/img]] for more details.
+
+ikiwiki 3.20160506 released with [[!toggle text="these changes"]]
+[[!toggleable text="""
+ * [ [[Simon McVittie|smcv]] ]
+   * HTML-escape error messages, in one case avoiding potential cross-site
+     scripting (OVE-20160505-0012)
+   * Mitigate ImageMagick vulnerabilities such as CVE-2016-3714:
+     - img: force common Web formats to be interpreted according to extension,
+       so that "allowed\_attachments: '*.jpg'" does what one might expect
+     - img: restrict to JPEG, PNG and GIF images by default, again mitigating
+       CVE-2016-3714 and similar vulnerabilities
+     - img: check that the magic number matches what we would expect from
+       the extension before giving common formats to ImageMagick
+   * d/control: use https for Homepage
+   * d/control: add Vcs-Browser
+ * [ [[Joey Hess|joey]] ]
+   * img: Add back support for SVG images, bypassing ImageMagick and
+     simply passing the SVG through to the browser, which is supported by all
+     commonly used browsers these days.
+     SVG scaling by img directives has subtly changed; where before
+     size=wxh would preserve aspect ratio, this cannot be done when passing
+     them through and so specifying both a width and height can change
+     the SVG's aspect ratio.
+   * loginselector: When only openid and emailauth are enabled, but
+     passwordauth is not, avoid showing a "Other" box which opens an
+     empty form.
+ * [ [[Amitai Schlair|schmonz]] ]
+   * mdwn: Process .md like .mdwn, but disallow web creation.
+ * [ Florian Wagner ]
+   * git: Correctly handle filenames starting with a dash in add/rm/mv."""]]

diff --git a/doc/todo/Correctly_handle_filenames_starting_with_a_dash_in_add__47__rm__47__mv.mdwn b/doc/todo/Correctly_handle_filenames_starting_with_a_dash_in_add__47__rm__47__mv.mdwn
new file mode 100644
index 0000000..5a34035
--- /dev/null
+++ b/doc/todo/Correctly_handle_filenames_starting_with_a_dash_in_add__47__rm__47__mv.mdwn
@@ -0,0 +1 @@
+BUG: Creating pages starting with dash(es) in the CGI doesn't add/commit them automatically to the GIT backend repository. This is fixed in the forked repository at <https://github.com/wagnerflo/ikiwiki> in commit [6b0ae40](https://github.com/wagnerflo/ikiwiki/commit/6b0ae40d109c58ae5ca098496ac30c7ef0074131).

Document the security fixes in this release
diff --git a/debian/NEWS b/debian/NEWS
index b2753c6..66b2b42 100644
--- a/debian/NEWS
+++ b/debian/NEWS
@@ -1,3 +1,27 @@
+ikiwiki (3.20160506) UNRELEASED; urgency=medium
+
+  To mitigate CVE-2016-3714 and similar ImageMagick security vulnerabilities,
+  the [[!img]] directive is now restricted to these common web formats by
+  default:
+
+  * JPEG (.jpg, .jpeg)
+  * PNG (.png)
+  * GIF (.gif)
+  * SVG (.svg)
+
+  (In particular, by default resizing PDF files is no longer allowed.)
+
+  Additionally, resized SVG files are displayed in the browser as SVG
+  instead of being converted to PNG.
+
+  If all users who can attach images are fully trusted, this restriction
+  can be removed with the new img_allowed_formats setup option.
+  See <https://ikiwiki.info/ikiwiki/directive/img/>
+  or <file:///usr/share/doc/ikiwiki/html/ikiwiki/directive/img.html> for
+  more details.
+
+ -- Simon McVittie <smcv@debian.org>  Fri, 06 May 2016 07:07:29 +0100
+
 ikiwiki (3.20150610) unstable; urgency=low
 
   The new "emailauth" plugin allows users to authenticate using an email
diff --git a/doc/ikiwiki/directive/img.mdwn b/doc/ikiwiki/directive/img.mdwn
index fa3b40f..a940a44 100644
--- a/doc/ikiwiki/directive/img.mdwn
+++ b/doc/ikiwiki/directive/img.mdwn
@@ -41,4 +41,27 @@ the page, unless overridden. Useful when including many images on a page.
 	\[[!img photo2.jpg]]
 	\[[!img photo3.jpg size=200x600]]
 
+## format support
+
+By default, the `img` directive only supports a few common web formats:
+
+* PNG (`.png`)
+* JPEG (`.jpg` or `.jpeg`)
+* GIF (`.gif`)
+* SVG (`.svg`)
+
+These additional formats can be enabled with the `img_allowed_formats`
+[[!iki setup]] option, but are disabled by default for better
+[[!iki security]]:
+
+* PDF (`.pdf`)
+* `everything` (accepts any file supported by ImageMagick: make sure
+  that only completely trusted users can
+  [[upload attachments|ikiwiki/pagespec/attachment]])
+
+For example, a wiki where only `admin()` users can upload attachments might
+use:
+
+    img_allowed_formats: [png, jpeg, gif, svg, pdf]
+
 [[!meta robots="noindex, follow"]]
diff --git a/doc/security.mdwn b/doc/security.mdwn
index d5a0266..6d4841f 100644
--- a/doc/security.mdwn
+++ b/doc/security.mdwn
@@ -178,7 +178,8 @@ the same standards as the rest of ikiwiki, but with that said, here are
 some security notes for them.
 
 * The [[plugins/img]] plugin assumes that imagemagick/perlmagick are secure
-  from malformed image attacks. Imagemagick has had security holes in the
+  from malformed image attacks for at least the formats listed in
+  `img_allowed_formats`. Imagemagick has had security holes in the
   past. To be able to exploit such a hole, a user would need to be able to
   upload images to the wiki.
 
@@ -506,3 +507,22 @@ The hole was reported on March 24th, a fix was developed on March 27th,
 and the fixed version 3.20150329 was released on the 29th. A fix was backported
 to Debian jessie as version 3.20141016.2 and to Debian wheezy as version
 3.20120629.2. An upgrade is recommended for sites using CGI and openid.
+
+## XSS via error messages
+
+CGI error messages did not escape HTML meta-characters, potentially
+allowing an attacker to carry out cross-site scripting by directing a
+user to a URL that would result in a crafted ikiwiki error message. This
+was discovered on 4 May by the ikiwiki developers, and the fixed version
+3.20160506 was released on 6 May. An upgrade is recommended for sites using
+the CGI.
+
+## ImageMagick CVE-2016–3714 ("ImageTragick")
+
+ikiwiki 3.20160506 attempts to mitigate [[!cve CVE-2016-3714]] and any
+future ImageMagick vulnerabilities that resemble it, by restricting the
+image formats that the [[ikiwiki/directive/img]] directive is willing to
+resize. An upgrade is recommended for sites where an untrusted user is
+able to attach images. Upgrading ImageMagick to a version where
+CVE-2016-3714 has been fixed is also recommended, but at the time of
+writing no such version is available.

Do not recommend mimetype(image/*)
Not all image file types are safe for general use: in particular,
image/svg+xml is known to be vulnerable to CVE-2016-3714 under some
ImageMagick configurations.
diff --git a/doc/ikiwiki/pagespec/attachment.mdwn b/doc/ikiwiki/pagespec/attachment.mdwn
index fa2bc58..868fb23 100644
--- a/doc/ikiwiki/pagespec/attachment.mdwn
+++ b/doc/ikiwiki/pagespec/attachment.mdwn
@@ -12,7 +12,7 @@ while allowing larger mp3 files to be uploaded by joey into a specific
 directory, and check all attachments for viruses, something like this could be
 used:
   
-	virusfree() and ((user(joey) and podcast/*.mp3 and mimetype(audio/mpeg) and maxsize(15mb)) or (mimetype(image/*) and maxsize(50kb)))
+	virusfree() and ((user(joey) and podcast/*.mp3 and mimetype(audio/mpeg) and maxsize(15mb)) or ((mimetype(image/jpeg) or mimetype(image/png)) and maxsize(50kb)))
 
 The regular [[ikiwiki/PageSpec]] syntax is expanded with the following
 additional tests:

img: Add back support for SVG images, bypassing ImageMagick and simply passing the SVG through to the browser
SVG scaling by img directives has subtly changed; where before size=wxh
would preserve aspect ratio, this cannot be done when passing them through
and so specifying both a width and height can change the SVG's aspect
ratio.
(This patch looks significantly more complex than it was, because a large
block of code had to be indented.)
[smcv: drop trailing whitespace, fix some spelling]
diff --git a/IkiWiki/Plugin/img.pm b/IkiWiki/Plugin/img.pm
index ed2e935..494fe23 100644
--- a/IkiWiki/Plugin/img.pm
+++ b/IkiWiki/Plugin/img.pm
@@ -23,8 +23,8 @@ sub getsetup () {
 		},
 		img_allowed_formats => {
 			type => "string",
-			default => [qw(jpeg png gif)],
-			description => "Image formats to process (jpeg, png, gif, pdf, svg or 'everything' to accept all)",
+			default => [qw(jpeg png gif svg)],
+			description => "Image formats to process (jpeg, png, gif, svg, pdf or 'everything' to accept all)",
 			# ImageMagick has had arbitrary code execution flaws,
 			# and the whole delegates mechanism is scary from
 			# that perspective
@@ -36,7 +36,7 @@ sub getsetup () {
 sub allowed {
 	my $format = shift;
 	my $allowed = $config{img_allowed_formats};
-	$allowed = ['jpeg', 'png'] unless defined $allowed && @$allowed;
+	$allowed = ['jpeg', 'png', 'gif', 'svg'] unless defined $allowed && @$allowed;
 
 	foreach my $a (@$allowed) {
 		return 1 if $a eq $format || $a eq 'everything';
@@ -131,17 +131,7 @@ sub preprocess (@) {
 	error sprintf(gettext("%s image processing disabled in img_allowed_formats configuration"), $format ? $format : "\"$extension\"") unless allowed($format ? $format : "everything");
 
 	# Try harder to protect ImageMagick from itself
-	if ($format eq 'svg') {
-		my $content;
-		read($in, $content, 5) or error sprintf(gettext("failed to read %s: %s"), $file, $!);
-		# This is an over-simplification, but ?xml is the check that
-		# ImageMagick uses. We also accept <svg for the simplest
-		# possible SVGs.
-		if ($content !~ m/^(.\?xml|<svg)/is) {
-			error sprintf(gettext("\"%s\" does not seem to be a valid %s file"), $file, $format);
-		}
-	}
-	elsif ($magic) {
+	if (defined $magic) {
 		my $content;
 		read($in, $content, length $magic) or error sprintf(gettext("failed to read %s: %s"), $file, $!);
 		if ($magic ne $content) {
@@ -149,94 +139,112 @@ sub preprocess (@) {
 		}
 	}
 
-	my $issvg = $base=~s/\.svg$/.png/i;
 	my $ispdf = $base=~s/\.pdf$/.png/i;
 	my $pagenumber = exists($params{pagenumber}) ? int($params{pagenumber}) : 0;
 	if ($pagenumber != 0) {
 		$base = "p$pagenumber-$base";
 	}
 
-	eval q{use Image::Magick};
-	error gettext("Image::Magick is not installed") if $@;
-	my $im = Image::Magick->new();
 	my $imglink;
 	my $imgdatalink;
-	my $r = $im->Read("$format:$srcfile\[$pagenumber]");
-	error sprintf(gettext("failed to read %s: %s"), $file, $r) if $r;
+	my ($dwidth, $dheight);
 
-	if (! defined $im->Get("width") || ! defined $im->Get("height")) {
-		error sprintf(gettext("failed to get dimensions of %s"), $file);
+	my ($w, $h);
+	if ($params{size} ne 'full') {
+		($w, $h) = ($params{size} =~ /^(\d*)x(\d*)$/);
 	}
 
-	my ($dwidth, $dheight);
+	if ($format eq 'svg') {
+		# svg images are not scaled using ImageMagick because the
+		# pipeline is complex. Instead, the image size is simply
+		# set to the provided values.
+		#
+		# Aspect ratio will be preserved automatically when
+		# only a width or only a height is specified.
+		# When both are specified, aspect ratio will not be
+		# preserved.
+		$imglink = $file;
+		$dwidth = $w if length $w;
+		$dheight = $h if length $h;
+	}
+	else {
+		eval q{use Image::Magick};
+		error gettext("Image::Magick is not installed") if $@;
+		my $im = Image::Magick->new();
+		my $r = $im->Read("$format:$srcfile\[$pagenumber]");
+		error sprintf(gettext("failed to read %s: %s"), $file, $r) if $r;
+
+		if (! defined $im->Get("width") || ! defined $im->Get("height")) {
+			error sprintf(gettext("failed to get dimensions of %s"), $file);
+		}
 
-	if ($params{size} eq 'full') {
-		$dwidth = $im->Get("width");
-		$dheight = $im->Get("height");
-	} else {
-		my ($w, $h) = ($params{size} =~ /^(\d*)x(\d*)$/);
-		error sprintf(gettext('wrong size format "%s" (should be WxH)'), $params{size})
-			unless (defined $w && defined $h &&
-			        (length $w || length $h));
-
-		if ($im->Get("width") == 0 || $im->Get("height") == 0) {
-			($dwidth, $dheight)=(0, 0);
-		} elsif (! length $w || (length $h && $im->Get("height")*$w > $h * $im->Get("width"))) {
-			# using height because only height is given or ...
-			# because original image is more portrait than $w/$h
-			# ... slimness of $im > $h/w
-			# ... $im->Get("height")/$im->Get("width") > $h/$w
-			# ... $im->Get("height")*$w > $h * $im->Get("width")
-
-			$dheight=$h;
-			$dwidth=$h / $im->Get("height") * $im->Get("width");
-		} else { # (! length $h) or $w is what determines the resized size
-			$dwidth=$w;
-			$dheight=$w / $im->Get("width") * $im->Get("height");
+		if (! length $w && ! length $h) {
+			$dwidth = $im->Get("width");
+			$dheight = $im->Get("height");
+		} else {
+			error sprintf(gettext('wrong size format "%s" (should be WxH)'), $params{size})
+				unless (defined $w && defined $h &&
+				        (length $w || length $h));
+
+			if ($im->Get("width") == 0 || $im->Get("height") == 0) {
+				($dwidth, $dheight)=(0, 0);
+			} elsif (! length $w || (length $h && $im->Get("height")*$w > $h * $im->Get("width"))) {
+				# using height because only height is given or ...
+				# because original image is more portrait than $w/$h
+				# ... slimness of $im > $h/w
+				# ... $im->Get("height")/$im->Get("width") > $h/$w
+				# ... $im->Get("height")*$w > $h * $im->Get("width")
+
+				$dheight=$h;
+				$dwidth=$h / $im->Get("height") * $im->Get("width");
+			} else { # (! length $h) or $w is what determines the resized size
+				$dwidth=$w;
+				$dheight=$w / $im->Get("width") * $im->Get("height");
+			}
 		}
-	}
 
-	if ($dwidth < $im->Get("width") || $ispdf) {
-		# resize down, or resize to pixels at all
+		if ($dwidth < $im->Get("width") || $ispdf) {
+			# resize down, or resize to pixels at all
 
-		my $outfile = "$config{destdir}/$dir/$params{size}-$base";
-		$imglink = "$dir/$params{size}-$base";
+			my $outfile = "$config{destdir}/$dir/$params{size}-$base";
+			$imglink = "$dir/$params{size}-$base";
 
-		will_render($params{page}, $imglink);
+			will_render($params{page}, $imglink);
 
-		if (-e $outfile && (-M $srcfile >= -M $outfile)) {
-			$im = Image::Magick->new;
-			$r = $im->Read($outfile);
-			error sprintf(gettext("failed to read %s: %s"), $outfile, $r) if $r;
-		}
-		else {
-			$r = $im->Resize(geometry => "${dwidth}x${dheight}");
-			error sprintf(gettext("failed to resize: %s"), $r) if $r;
-
-			$im->set(($issvg || $ispdf) ? (magick => 'png') : ());
-			my @blob = $im->ImageToBlob();
-			# don't actually write resized file in preview mode;
-			# rely on width and height settings
-			if (! $params{preview}) {
-				writefile($imglink, $config{destdir}, $blob[0], 1);
+			if (-e $outfile && (-M $srcfile >= -M $outfile)) {
+				$im = Image::Magick->new;
+				$r = $im->Read($outfile);
+				error sprintf(gettext("failed to read %s: %s"), $outfile, $r) if $r;
 			}
 			else {
-				eval q{use MIME::Base64};
-				error($@) if $@;
-				$imgdatalink = "data:image/".$im->Get("magick").";base64,".encode_base64($blob[0]);
+				$r = $im->Resize(geometry => "${dwidth}x${dheight}");
+				error sprintf(gettext("failed to resize: %s"), $r) if $r;
+
+				$im->set($ispdf ? (magick => 'png') : ());
+				my @blob = $im->ImageToBlob();
+				# don't actually write resized file in preview mode;
+				# rely on width and height settings
+				if (! $params{preview}) {
+					writefile($imglink, $config{destdir}, $blob[0], 1);
+				}
+				else {
+					eval q{use MIME::Base64};
+					error($@) if $@;
+					$imgdatalink = "data:image/".$im->Get("magick").";base64,".encode_base64($blob[0]);
+				}
 			}
+
+			# always get the true size of the resized image (it could be
+			# that imagemagick did its calculations differently)

(Diff truncated)
all good
diff --git a/doc/bugs/footnotes-look-weird.mdwn b/doc/bugs/footnotes-look-weird.mdwn
index d085e9b..be1e5d5 100644
--- a/doc/bugs/footnotes-look-weird.mdwn
+++ b/doc/bugs/footnotes-look-weird.mdwn
@@ -90,7 +90,9 @@ screen readers), as detailed in [this Stack Overflow discussion][].
 >>> headers) or likely to trigger by mistake (typographic quotes and
 >>> [[maybe alpha lists|forum/"S."_gets_replace_by_"a."_in_my_ikiwiki]]).
 >>> --[[smcv]]
->>
+>>>
+>>>> Makes perfect sense to me. --[[anarcat]]
+>>>
 >> For example, to enable footnotes, one needs to call Discount like this:
 >> 
 >>       Text::Markdown::Discount::markdown($text, Text::Markdown::Discount::MKD_EXTRA_FOOTNOTE())
@@ -117,6 +119,9 @@ screen readers), as detailed in [this Stack Overflow discussion][].
 >>> `a.footnote` if the HTML produced by some other htmlize hook was
 >>> `<sup><a class="footnote" ...>[1]</a></sup>` for instance.
 >>> But they're probably harmless.
+>>>
+>>>> Alright, your call. :) At least this bug will be available as a workaround
+>>>> for others that stumble upon the same problem! :) --[[anarcat]]
 
 Note that I also make the bottom `<div>` small as well so that it has
 less weight than the rest of the text. -- [[anarcat]]

diff --git a/doc/bugs/footnotes-look-weird.mdwn b/doc/bugs/footnotes-look-weird.mdwn
index 7ea9f24..d085e9b 100644
--- a/doc/bugs/footnotes-look-weird.mdwn
+++ b/doc/bugs/footnotes-look-weird.mdwn
@@ -76,6 +76,21 @@ screen readers), as detailed in [this Stack Overflow discussion][].
 >> are enabled in their configuration, but I understand that makes the
 >> configuration more complicated and error-prone.
 >>
+>>> Discount enables enough features by default that adding footnotes doesn't
+>>> seem bad to me. I'm also tempted by something like
+>>>
+>>> ```
+>>> mdwn_enable: [footnotes]
+>>> mdwn_disable: [alphalist, superscript]
+>>> ```
+>>>
+>>> where the default for anything that was neither specifically enabled
+>>> nor specifically disabled would be to enable everything that we don't
+>>> think is a poor fit for the processing model (pandoc-style document
+>>> headers) or likely to trigger by mistake (typographic quotes and
+>>> [[maybe alpha lists|forum/"S."_gets_replace_by_"a."_in_my_ikiwiki]]).
+>>> --[[smcv]]
+>>
 >> For example, to enable footnotes, one needs to call Discount like this:
 >> 
 >>       Text::Markdown::Discount::markdown($text, Text::Markdown::Discount::MKD_EXTRA_FOOTNOTE())
@@ -90,6 +105,18 @@ screen readers), as detailed in [this Stack Overflow discussion][].
 >>
 >> In the meantime, wouldn't it be better to have some styling here to
 >> workaround the problem in MMD?
+>>
+>>> Honestly, I'd rather have ikiwiki's level of support for the non-preferred
+>>> Markdown implementation be: if you are stuck on a platform with no C compiler
+>>> or Perl headers, you can use the pure-Perl Markdown flavours, and they
+>>> will sort of mostly work (but might not look great).
+>>>
+>>> I'm a little concerned that styling these rather generically-named classes
+>>> might interfere with the implementations of footnotes in other Markdown
+>>> implementations, or indeed non-Markdown - I wouldn't want to style
+>>> `a.footnote` if the HTML produced by some other htmlize hook was
+>>> `<sup><a class="footnote" ...>[1]</a></sup>` for instance.
+>>> But they're probably harmless.
 
 Note that I also make the bottom `<div>` small as well so that it has
 less weight than the rest of the text. -- [[anarcat]]

response: confirmation it's a bug in MMD and Discount doesn't have footnotes, and request for workaround
diff --git a/doc/bugs/footnotes-look-weird.mdwn b/doc/bugs/footnotes-look-weird.mdwn
index 86a1323..7ea9f24 100644
--- a/doc/bugs/footnotes-look-weird.mdwn
+++ b/doc/bugs/footnotes-look-weird.mdwn
@@ -62,5 +62,34 @@ screen readers), as detailed in [this Stack Overflow discussion][].
 > summary?
 > --[[smcv]]
 
+>> That is an accurate summary.
+>>
+>> I didn't realize that Discount didn't actually support footnotes in
+>> Ikiwiki by default. I guess I enabled Multimarkdown exactly for that
+>> kind of stuff that was missing...  It seems to me it would be
+>> reasonable to enable footnotes in Ikiwiki. There's already a lot of
+>> stuff that Discount does that is way more exotic (e.g. tables) and
+>> non-standard (e.g. `abbr:`).
+>>
+>> Ideally, users would get to configure which
+>> [Discount flags](http://www.pell.portland.or.us/~orc/Code/markdown/#flags)
+>> are enabled in their configuration, but I understand that makes the
+>> configuration more complicated and error-prone.
+>>
+>> For example, to enable footnotes, one needs to call Discount like this:
+>> 
+>>       Text::Markdown::Discount::markdown($text, Text::Markdown::Discount::MKD_EXTRA_FOOTNOTE())
+>>
+>> That being said, Discount generates proper semantic markup when
+>> footnotes, so this bug doesn't apply to the default Discount mode,
+>> if we ignore the fact that it doesn't support footnotes at all.
+>> Should I open a todo about this and the above?
+>>
+>> Also, it seems this *is* a bug with multimarkdown - I have
+>> [reported the issue there](https://github.com/bobtfish/text-multimarkdown/issues/30).
+>>
+>> In the meantime, wouldn't it be better to have some styling here to
+>> workaround the problem in MMD?
+
 Note that I also make the bottom `<div>` small as well so that it has
 less weight than the rest of the text. -- [[anarcat]]

discount (as used on this wiki) can do footnotes, but they aren't enabled by ikiwiki
diff --git a/doc/bugs/footnotes-look-weird.mdwn b/doc/bugs/footnotes-look-weird.mdwn
index 3fb8f4b..86a1323 100644
--- a/doc/bugs/footnotes-look-weird.mdwn
+++ b/doc/bugs/footnotes-look-weird.mdwn
@@ -48,6 +48,13 @@ screen readers), as detailed in [this Stack Overflow discussion][].
 > If so, please report that as a MultiMarkdown bug, not an ikiwiki bug,
 > or alternatively don't use MultiMarkdown.
 >
+> The recommended backend for the [[plugins/mdwn]] plugin is
+> [[!cpan Text::Markdown::Discount]], which optionally implements
+> footnotes using the same syntax as MultiMarkdown (originating in
+> "PHP Markdown Extra"). However, ikiwiki doesn't currently enable
+> that particular feature. Maybe it should, at least via a site-wide
+> option.
+>
 > What remains after eliminating the MultiMarkdown bug seems to be:
 > ikiwiki's default stylesheet does not contain the necessary styling
 > to work around the non-semantic markup produced by the non-default

response
diff --git a/doc/bugs/footnotes-look-weird.mdwn b/doc/bugs/footnotes-look-weird.mdwn
index a5af38e..3fb8f4b 100644
--- a/doc/bugs/footnotes-look-weird.mdwn
+++ b/doc/bugs/footnotes-look-weird.mdwn
@@ -37,8 +37,23 @@ At any rate, the correct way to fix this is to *avoid* custom styling
 and use the `<sup>` tag for the footnote reference, as it has
 *meaning* which is important to have proper semantic output (e.g. for
 screen readers), as detailed in [this Stack Overflow discussion][].
+--[[anarcat]]
 
 [this Stack Overflow discussion]: http://stackoverflow.com/questions/501671/superscript-in-css-only
 
+> ikiwiki code does not interpret Markdown or translate it into HTML.
+> If I'm interpreting what you say correctly, you seem to be implying
+> that you think [[!cpan Text::MultiMarkdown]] is producing incorrect
+> HTML for footnotes (is an `<a>` with a `class`, should be a `<sup>`).
+> If so, please report that as a MultiMarkdown bug, not an ikiwiki bug,
+> or alternatively don't use MultiMarkdown.
+>
+> What remains after eliminating the MultiMarkdown bug seems to be:
+> ikiwiki's default stylesheet does not contain the necessary styling
+> to work around the non-semantic markup produced by the non-default
+> Text::MultiMarkdown Markdown implementation. Is that an accurate
+> summary?
+> --[[smcv]]
+
 Note that I also make the bottom `<div>` small as well so that it has
 less weight than the rest of the text. -- [[anarcat]]

response
diff --git a/doc/bugs/cannot_login.mdwn b/doc/bugs/cannot_login.mdwn
index 96d2bad..d8a8d5a 100644
--- a/doc/bugs/cannot_login.mdwn
+++ b/doc/bugs/cannot_login.mdwn
@@ -72,3 +72,14 @@ Update2: it seems this is specific to the HTTP/HTTPS switch. If I use HTTPS, thi
 >> And indeed, there seems to be a HTTPS-related issue: both login mechanisms
 >> work fine when on HTTPS, and both fail on HTTP. So I don't see those things
 >> as being necessarily distinct. -- [[anarcat]]
+
+>>> I've explained how the "login failed, perhaps you need to turn on
+>>> cookies?" can happen and what it means. Clearly nothing to do with
+>>> http; clearly not specific to branchable.
+>>> 
+>>> I just now logged into this site using openid over http, and it worked
+>>> ok. I think it's more likely that the `time_bad_sig` problem occurs
+>>> intermittently (which would make sense if it's a timing related issue),
+>>> and so you've just so happened to see it when logging in with
+>>> http and not https, than that there's actually a correlation.
+>>> --[[Joey]]

diff --git a/doc/todo/merge_bootstrap_branch.mdwn b/doc/todo/merge_bootstrap_branch.mdwn
index a928e14..ee42bf5 100644
--- a/doc/todo/merge_bootstrap_branch.mdwn
+++ b/doc/todo/merge_bootstrap_branch.mdwn
@@ -14,3 +14,10 @@ did them in a way that makes the diff pretty clear that nothing changes
 except when the bootstrap theme is enabled.
 
 --[[Joey]]
+
+> [bootstrap3 is in debian](https://tracker.debian.org/pkg/twitter-bootstrap3).
+> As far as I know, there is no effort to package b4 just yet,
+> maybe a RFP?
+>
+> My work on bootstrap also involved some changes to the base templates,
+> not sure there is a way to work around that. --[[anarcat]]

response
diff --git a/doc/bugs/cannot_login.mdwn b/doc/bugs/cannot_login.mdwn
index c2c4d91..96d2bad 100644
--- a/doc/bugs/cannot_login.mdwn
+++ b/doc/bugs/cannot_login.mdwn
@@ -60,3 +60,15 @@ Update2: it seems this is specific to the HTTP/HTTPS switch. If I use HTTPS, thi
 > to go back to a previous login form and try to reuse it.
 > 
 > --[[Joey]]
+
+>> I am sorry. I thought the problem was originally related to ikiwiki
+>> then figured it was *only* happening on branchable sites, so I figured
+>> it was better to report it on the branchable.com forums.
+>>
+>> I know that there's a OpenID-specific issue, but I had such issues in
+>> the past and succesfuly solved those. Because the timing of the emergence
+>> of the problem, i felt there was a correlation between the two issues.
+>>
+>> And indeed, there seems to be a HTTPS-related issue: both login mechanisms
+>> work fine when on HTTPS, and both fail on HTTP. So I don't see those things
+>> as being necessarily distinct. -- [[anarcat]]

Merge branch 'master' of ssh://git.ikiwiki.info
response
diff --git a/doc/bugs/cannot_login.mdwn b/doc/bugs/cannot_login.mdwn
index a4f1295..cd13ba3 100644
--- a/doc/bugs/cannot_login.mdwn
+++ b/doc/bugs/cannot_login.mdwn
@@ -38,3 +38,23 @@ Thanks. --[[anarcat]]
 
 Update: now I can't login to the ikiwiki.info site anymore, getting
 the same errors as on the git-annex site.
+
+> This seems to be a concacentation of multiple unrelated problems with
+> different stuff, which is not a good bug report technique. Then to add to
+> the fun, you filed the same bug on branchable too. Sigh!
+> 
+> The `time_bad_sig` problem with the perl openid library is a problem I am
+> aware of but it's not clear if the problem is clock skew, or a protocol
+> problem. At least one user to report it seemed to get it due to a http
+> proxy. I'm pretty sure it could also happen if multiple openid logins
+> were attempted at the same time (the `consumer_secret` which is stored
+> server-side is used). The problem is not specific to ikiwiki.
+> 
+> Ikiwiki says "login failed, perhaps you need to turn on cookies?" when
+> the user successfully logged in, but their cookie does not indicate why
+> they were logging in to begin with, so ikiwiki does not know what action
+> to continue to. One way to get this when cookies are enabled is to
+> re-post a login form after already using it, by eg using the back button
+> to go back to a previous login form and try to reuse it.
+> 
+> --[[Joey]]

diff --git a/doc/bugs/cannot_login.mdwn b/doc/bugs/cannot_login.mdwn
index c0537e8..c363f07 100644
--- a/doc/bugs/cannot_login.mdwn
+++ b/doc/bugs/cannot_login.mdwn
@@ -39,4 +39,4 @@ Thanks. --[[anarcat]]
 Update: now I can't login to the ikiwiki.info site anymore, getting
 the same errors as on the git-annex site.
 
-Update2: it seems this is specific to the HTTP/HTTPS switch. If I use HTTPS, things work fine, but not with plain HTTP.
+Update2: it seems this is specific to the HTTP/HTTPS switch. If I use HTTPS, things work fine, but not with plain HTTP. So I'm moving this to the branchable wiki, as I am not having that problem on other ikiwiki sites. Maybe the bug specific to ikiwiki is the lack of clarity in figuring out wth is going on here... See <http://www.branchable.com/bugs/login_failures_without_https>

http/https issue
diff --git a/doc/bugs/cannot_login.mdwn b/doc/bugs/cannot_login.mdwn
index a4f1295..c0537e8 100644
--- a/doc/bugs/cannot_login.mdwn
+++ b/doc/bugs/cannot_login.mdwn
@@ -38,3 +38,5 @@ Thanks. --[[anarcat]]
 
 Update: now I can't login to the ikiwiki.info site anymore, getting
 the same errors as on the git-annex site.
+
+Update2: it seems this is specific to the HTTP/HTTPS switch. If I use HTTPS, things work fine, but not with plain HTTP.

smaller is too small for large blocks
diff --git a/doc/bugs/footnotes-look-weird.mdwn b/doc/bugs/footnotes-look-weird.mdwn
index 9ce3870..a5af38e 100644
--- a/doc/bugs/footnotes-look-weird.mdwn
+++ b/doc/bugs/footnotes-look-weird.mdwn
@@ -9,7 +9,7 @@ way to demonstrate this here, you'll have to trust me on this. :)
 The following stylesheet should be added to `style.css`:
 
     a.footnote { vertical-align: super; font-size: xx-small; }
-    div.footnotes { font-size: smaller; }
+    div.footnotes { font-size: small; }
 
 This is a typical style that user-agents apply to the `<sup>` tag. For
 example, chromium has this builtin style for `<sup>`:

fix typo and comment
diff --git a/doc/bugs/footnotes-look-weird.mdwn b/doc/bugs/footnotes-look-weird.mdwn
index 4747353..9ce3870 100644
--- a/doc/bugs/footnotes-look-weird.mdwn
+++ b/doc/bugs/footnotes-look-weird.mdwn
@@ -3,10 +3,13 @@ wiki, they don't look so good with the default stylesheet, however, as
 the references are in the same size and positioning as everything
 else.
 
+This particular wiki does not use multimarkdown, so there's no easy
+way to demonstrate this here, you'll have to trust me on this. :)
+
 The following stylesheet should be added to `style.css`:
 
     a.footnote { vertical-align: super; font-size: xx-small; }
-    div.footnote { font-size: smaller; }
+    div.footnotes { font-size: smaller; }
 
 This is a typical style that user-agents apply to the `<sup>` tag. For
 example, chromium has this builtin style for `<sup>`:

new CSS bug
diff --git a/doc/bugs/footnotes-look-weird.mdwn b/doc/bugs/footnotes-look-weird.mdwn
new file mode 100644
index 0000000..4747353
--- /dev/null
+++ b/doc/bugs/footnotes-look-weird.mdwn
@@ -0,0 +1,41 @@
+Multimarkdown footnotes are pretty useful. If they are enabled in a
+wiki, they don't look so good with the default stylesheet, however, as
+the references are in the same size and positioning as everything
+else.
+
+The following stylesheet should be added to `style.css`:
+
+    a.footnote { vertical-align: super; font-size: xx-small; }
+    div.footnote { font-size: smaller; }
+
+This is a typical style that user-agents apply to the `<sup>` tag. For
+example, chromium has this builtin style for `<sup>`:
+
+    vertical-align: super;
+    font-size: smaller;
+
+Bootstrap uses this instead:
+
+    sup {
+        top: -.5em;
+    }
+    
+    sub, sup {
+        position: relative;
+        font-size: 75%;
+        line-height: 0;
+        vertical-align: baseline;
+    }
+
+I settled on `xx-small` because it's the only size that doesn't affect
+line-height here. However, Bootstrap's way may be better.
+
+At any rate, the correct way to fix this is to *avoid* custom styling
+and use the `<sup>` tag for the footnote reference, as it has
+*meaning* which is important to have proper semantic output (e.g. for
+screen readers), as detailed in [this Stack Overflow discussion][].
+
+[this Stack Overflow discussion]: http://stackoverflow.com/questions/501671/superscript-in-css-only
+
+Note that I also make the bottom `<div>` small as well so that it has
+less weight than the rest of the text. -- [[anarcat]]

explain footnotes
diff --git a/doc/tips/convert_moinmoin_to_ikiwiki.mdwn b/doc/tips/convert_moinmoin_to_ikiwiki.mdwn
index 4b3deb2..492418b 100644
--- a/doc/tips/convert_moinmoin_to_ikiwiki.mdwn
+++ b/doc/tips/convert_moinmoin_to_ikiwiki.mdwn
@@ -46,7 +46,7 @@ Usage instructions are in the `README` file.
    vertical list instead of an horizontal list)
  * PageList, through [[ikiwiki/directive/map]]
  * MonthCalendar, partially, through [[ikiwiki/directive/calendar]]
- * FootNote, through markdown
+ * FootNote, through multimarkdown (`[^foo]` → `[^foo]: this is the footnote`)
  * Anchor, through markdown and plain HTML
  * `<<BR>>`, through the weird line ending thing
  * AttachList, through a weird [[ikiwiki/directive/inline]]

Changed the expired domain and added question
diff --git a/doc/bugs/Anon_edit_caused_lock_out_on_entire_site_.mdwn b/doc/bugs/Anon_edit_caused_lock_out_on_entire_site_.mdwn
index dc79bba..a669413 100644
--- a/doc/bugs/Anon_edit_caused_lock_out_on_entire_site_.mdwn
+++ b/doc/bugs/Anon_edit_caused_lock_out_on_entire_site_.mdwn
@@ -30,7 +30,7 @@ The `anonok` plugin is **not** enabled
 
 ## Steps
 
-I've tried to place a comment clicking in the obvious [Add a comment](https://dev.iikb.org/ikiwiki.cgi?do=comment&page=forum%2FTema_bootstrap) in a [forum post](https://dev.iikb.org/forum/Tema_bootstrap/).
+I've tried to place a comment clicking in the obvious [Add a comment](https://dev.iikb.xyz/ikiwiki.cgi?do=comment&page=forum%2FTema_bootstrap) in a [forum post](https://dev.iikb.xyz/forum/Tema_bootstrap/).
 
 I've not signed in because the *sign in* page didn't come up, instead a simple `(You might want to Signin first?)` showed up, which I've haven't read and commented away.
 
@@ -38,9 +38,9 @@ I've not signed in because the *sign in* page didn't come up, instead a simple `
 
 ## Results
 
-As a consequence of that, the user '' - that's a null character, have somehow logged in and it seems that there is no way to [log it out](https://dev.iikb.org/ikiwiki.cgi?do=prefs).
+As a consequence of that, the user '' - that's a null character, have somehow logged in and it seems that there is no way to [log it out](https://dev.iikb.xyz/ikiwiki.cgi?do=prefs).
 
-None of this phantom user edits are being commited - this [blog post](https://dev.iikb.org/blog/posts/Bug_severo_neste_site/) was made with that user logged in via web.
+None of this phantom user edits are being commited - this [blog post](https://dev.iikb.xyz/blog/posts/Bug_severo_neste_site/) was made with that user logged in via web.
 
 It seems I can't log out from nowhere. I've rebuild the wiki from the command line and restarted the nginx server, the phantom user remains logged in and open to anyone willing to edit away the wiki.
 
@@ -50,4 +50,10 @@ It seems I can't log out from nowhere. I've rebuild the wiki from the command li
 
 If I wanted to do a totally anonnymous wiki, this would be the best setup ever.
 
-For [this particular installation](https://dev.iikb.org), that's not the case.
+For [this particular installation](https://dev.iikb.xyz), that's not the case.
+
+---
+
+## Question
+
+Is there a session file or something to logout this phantom user?

Fixed dead link.
diff --git a/doc/tips/Importing_posts_from_Wordpress.mdwn b/doc/tips/Importing_posts_from_Wordpress.mdwn
index 6dc9734..64c995e 100644
--- a/doc/tips/Importing_posts_from_Wordpress.mdwn
+++ b/doc/tips/Importing_posts_from_Wordpress.mdwn
@@ -2,7 +2,7 @@
 
 Use case: You want to move away from Wordpress to Ikiwiki as your blogging/website platform, but you want to retain your old posts.
 
-[This](http://git.chris-lamb.co.uk/?p=ikiwiki-wordpress-import.git) is a simple tool that generates [git-fast-import](http://www.kernel.org/pub/software/scm/git/docs/git-fast-import.html)-compatible data from a WordPress export XML file.
+[This](https://chris-lamb.co.uk/projects/ikiwiki-wordpress-import) is a simple tool that generates [git-fast-import](http://www.kernel.org/pub/software/scm/git/docs/git-fast-import.html)-compatible data from a WordPress export XML file.
 
 WordPress categories are mapped onto Ikiwiki tags. The ability to import comments is planned.
 

add screenshot
diff --git a/doc/todo/admonitions.mdwn b/doc/todo/admonitions.mdwn
index 0f47901..50f62bf 100644
--- a/doc/todo/admonitions.mdwn
+++ b/doc/todo/admonitions.mdwn
@@ -118,4 +118,8 @@ bangs and all...
 [admon-caution.png]: https://moinmo.in/moin_static19/modernized/img/admon-caution.png
 
 Update: I have made a [[plugins/contrib/admonition]] plugin for this
-purpose, as a patch. Hopefully it will be mergeable here?
+purpose, as a patch. Hopefully it will be mergeable here? Here's a
+screenshot of what the help page would look like, to give you an idea
+of the results:
+
+<img src="http://paste.anarc.at/snaps/snap-2016.04.15-18.07.39.png" />

fix typos
diff --git a/doc/plugins/contrib/admonition.mdwn b/doc/plugins/contrib/admonition.mdwn
index de71738..43c63e4 100644
--- a/doc/plugins/contrib/admonition.mdwn
+++ b/doc/plugins/contrib/admonition.mdwn
@@ -9,11 +9,11 @@ sections of text using a custom style sheet and bright icons.
 
 5 directives are available:
 
-* [[ikiwiki/directives/tip]]
-* [[ikiwiki/directives/note]]
-* [[ikiwiki/directives/important]]
-* [[ikiwiki/directives/caution]]
-* [[ikiwiki/directives/warning]]
+* [[ikiwiki/directive/tip]]
+* [[ikiwiki/directive/note]]
+* [[ikiwiki/directive/important]]
+* [[ikiwiki/directive/caution]]
+* [[ikiwiki/directive/warning]]
 
 Or, in Ikiwiki markup:
 

announce the admonition plugin
diff --git a/doc/plugins/contrib/admonition.mdwn b/doc/plugins/contrib/admonition.mdwn
new file mode 100644
index 0000000..de71738
--- /dev/null
+++ b/doc/plugins/contrib/admonition.mdwn
@@ -0,0 +1,56 @@
+[[!meta author="anarcat"]]
+[[!template id=plugin name=admonition author="[[anarcat]]"]]
+[[!tag type/chrome]]
+
+# Admonitions
+
+This plugin adds directives that allow users to outline certain
+sections of text using a custom style sheet and bright icons.
+
+5 directives are available:
+
+* [[ikiwiki/directives/tip]]
+* [[ikiwiki/directives/note]]
+* [[ikiwiki/directives/important]]
+* [[ikiwiki/directives/caution]]
+* [[ikiwiki/directives/warning]]
+
+Or, in Ikiwiki markup:
+
+    \[[!tip "Lorem ipsum dolor sit amet, consectetuer adipiscing elit."]]
+    \[[!note "Vivamus id enim."]]
+    \[[!important "In id erat non orci commodo lobortis."]]
+    \[[!caution "In id erat non orci commodo lobortis."]]
+    \[[!warning "Phasellus neque orci, porta a, aliquet quis, semper a, massa."]]
+
+Those directives simply create a `<div>` elements in the right
+style. So the above can also be simply written as:
+
+    <div class="tip">Lorem ipsum dolor sit amet, consectetuer adipiscing elit.</div>
+    <div class="note">Vivamus id enim.</div>
+    <div class="important">In id erat non orci commodo lobortis.</div>
+    <div class="caution">In id erat non orci commodo lobortis.</div>
+    <div class="warning">Phasellus neque orci, porta a, aliquet quis, semper a, massa.</div>
+
+# Rationale
+
+The idea behind the directives is to make the the CSS elements easier
+to discover through the builtin documentation. Obviously, more
+admonitions can be created simply by adding similar icons and CSS
+elements. Of course, you will not get the above directives expanded
+automatically unless you patch the admonition plugin, unfortunately.
+
+# Code
+
+[[!template id=gitbranch branch=anarcat/admonitions author="[[anarcat]]"]]
+
+The [[!taglink patch]] is available from
+[anarcat's "admonition" branch][] and is designed to be merged in
+Ikiwiki directly:
+
+    git clone -b admonitions git://src.anarc.at/ikiwiki.git
+
+[anarcat's "admonition" branch]: http://src.anarc.at/ikiwiki.git/shortlog/refs/heads/admonitions
+
+See also [[todo/admonitions]] for the discussion leading to the
+creation of this plugin.
diff --git a/doc/todo/admonitions.mdwn b/doc/todo/admonitions.mdwn
index 7523aba..0f47901 100644
--- a/doc/todo/admonitions.mdwn
+++ b/doc/todo/admonitions.mdwn
@@ -116,3 +116,6 @@ bangs and all...
 [admon-tip.png]: https://moinmo.in/moin_static19/modernized/img/admon-tip.png
 [admon-important.png]: https://moinmo.in/moin_static19/modernized/img/admon-important.png
 [admon-caution.png]: https://moinmo.in/moin_static19/modernized/img/admon-caution.png
+
+Update: I have made a [[plugins/contrib/admonition]] plugin for this
+purpose, as a patch. Hopefully it will be mergeable here?

elaborate copyright investigation. ugh.
diff --git a/doc/todo/admonitions.mdwn b/doc/todo/admonitions.mdwn
index 80c1a30..7523aba 100644
--- a/doc/todo/admonitions.mdwn
+++ b/doc/todo/admonitions.mdwn
@@ -87,3 +87,32 @@ bangs and all...
 >> creating associated styles. Is that something you would be open to?
 >>
 >> --[[anarcat]]
+
+>> Looking more at the MoinMoin images, the source (and license!) for
+>> them is not quite clear, so they don't make such great targets for
+>> inclusion. They are, nevertheless, included in Debian so presumably
+>> they are DFSG-friendly? The copyright file marks them as "UNKNOWN"
+>> which is worrisome... I have found the following results about them:
+>>
+>> * [admon-warning.png][] seems to be [public domain according to this sketchy site][]
+>> * [admon-note.png][] seems to have a [source in XFCE][], as part of
+>>   the notes plugin
+>> * [admon-tip.png][] is used in the Debian release notes, so is
+>presumably fine as well [source there](https://www.debian.org/releases/testing/amd64/release-notes/images/note.png)
+>> * [admon-important.png][], same, [important.png](https://www.debian.org/releases/testing/amd64/release-notes/images/important.png)
+>> * [admon-caution.png][] can be found in Mediawiki as well, which is
+>> a good source of icons. According to Debian, some are public domain,
+>> some are LGPL (!?). In MediaWiki itself, the source of that file is
+>> lost in the mists of time.
+>>
+>> Even though there is some confusion about the source of those
+>> images, I think, in good faith, that they can be generally be
+>> considered reusable. --[[anarcat]]
+
+[public domain according to this sketchy site]: http://all-free-download.com/free-vector/download/tango_process_stop_115912.html
+[source in XFCE]: http://git.xfce.org/panel-plugins/xfce4-notes-plugin/tree/data/icons/scalable/xfce4-notes-plugin.svg
+[admon-warning.png]: https://moinmo.in/moin_static19/modernized/img/admon-warning.png
+[admon-note.png]: https://moinmo.in/moin_static19/modernized/img/admon-note.png
+[admon-tip.png]: https://moinmo.in/moin_static19/modernized/img/admon-tip.png
+[admon-important.png]: https://moinmo.in/moin_static19/modernized/img/admon-important.png
+[admon-caution.png]: https://moinmo.in/moin_static19/modernized/img/admon-caution.png

response
diff --git a/doc/todo/admonitions.mdwn b/doc/todo/admonitions.mdwn
index fb3268c..80c1a30 100644
--- a/doc/todo/admonitions.mdwn
+++ b/doc/todo/admonitions.mdwn
@@ -66,3 +66,24 @@ bangs and all...
 > There's a "note" template bundled with ikiwiki already.
 >
 > --[[smcv]]
+
+>> I think you mean the `htmlize` hook, as I cannot find any `htmlize`
+>> plugin.. That said, yeah, i understand the limitations of Ikiwiki
+>> here. I guess that the [[ikiwiki/directive/template]] directive is a
+>> good workaround, but it's not really shorter to write:
+>>
+>>     \[[!template id=warning text="Do as I say, not as I do."]]
+>>
+>> than to write:
+>>
+>> [[!format txt """<div class="warning">Do as I say, not as I do.</div>"""]]
+>>
+>> ... in fact, it's actually longer. So short of allowing arbitrary
+>> classes *and* fenced blocks, I don't think this can go much
+>> further.
+>>
+>> We *could*, however, import the admonition styles from MoinMoin
+>> directly. It would involve importing 5 icons from MoinMoin and
+>> creating associated styles. Is that something you would be open to?
+>>
+>> --[[anarcat]]

can't login again
diff --git a/doc/bugs/cannot_login.mdwn b/doc/bugs/cannot_login.mdwn
index 4574fbe..a4f1295 100644
--- a/doc/bugs/cannot_login.mdwn
+++ b/doc/bugs/cannot_login.mdwn
@@ -35,3 +35,6 @@ So I guess the problem is mostly with git-annex.branchable.com? Not
 sure how to debug this further.
 
 Thanks. --[[anarcat]]
+
+Update: now I can't login to the ikiwiki.info site anymore, getting
+the same errors as on the git-annex site.

escape
diff --git a/doc/todo/admonitions.mdwn b/doc/todo/admonitions.mdwn
index 2b777b3..fb3268c 100644
--- a/doc/todo/admonitions.mdwn
+++ b/doc/todo/admonitions.mdwn
@@ -61,7 +61,7 @@ bangs and all...
 > [[templates|ikiwiki/directive/template]] are another way this could
 > work:
 >
->     [[!template id=warning text="Do as I say, not as I do."]]
+>     \[[!template id=warning text="Do as I say, not as I do."]]
 >
 > There's a "note" template bundled with ikiwiki already.
 >

templates are another way to do this
diff --git a/doc/todo/admonitions.mdwn b/doc/todo/admonitions.mdwn
index 752eec3..2b777b3 100644
--- a/doc/todo/admonitions.mdwn
+++ b/doc/todo/admonitions.mdwn
@@ -56,4 +56,13 @@ bangs and all...
 > might use the right one?) could interpret an ad-hoc syntax and
 > turn it into a `<div>` either before or after `htmlize` processing.
 > However, that would be adding an extra layer of syntax for your
-> users to keep track of. --[[smcv]]
+> users to keep track of.
+>
+> [[templates|ikiwiki/directive/template]] are another way this could
+> work:
+>
+>     [[!template id=warning text="Do as I say, not as I do."]]
+>
+> There's a "note" template bundled with ikiwiki already.
+>
+> --[[smcv]]

diff --git a/doc/todo/admonitions.mdwn b/doc/todo/admonitions.mdwn
index 3d5b7f1..752eec3 100644
--- a/doc/todo/admonitions.mdwn
+++ b/doc/todo/admonitions.mdwn
@@ -23,3 +23,37 @@ bangs and all...
 
 [MoinMoin wiki]: https://moinmo.in/
 [Admonitions]: https://moinmo.in/HelpOnAdmonitions
+
+> ikiwiki's general design is that it supports exactly three forms
+> of markup:
+>
+> * whatever the `htmlize` plugin does
+> * as a special ikiwiki-specific extension, \[[wikilinks]]
+> * as another special ikiwiki-specific extension, \[[!directives]]
+>
+> All markup interpretation beyond wikilinks and directives is
+> the `htmlize` plugin's responsibility. The `mdwn` plugin
+> interprets Markdown, the `rst` plugin interprets
+> reStructuredText and so on.
+>
+> It sounds as though you're asking for a `htmlize` plugin which
+> interprets an extended dialect of Markdown:
+>
+> * standard Markdown (inasmuch as such a thing exists) as usual
+> * mapping certain syntax (what?) to "admonitions"
+>
+> ikiwiki deliberately doesn't implement Markdown parsing, it just
+> calls out to one of several Perl implementations of Markdown.
+>
+> Alternatively, you could have a small plugin that translates
+>
+>     [[!warning "Do what I say, not as I do."]]
+>
+> into an appropriate `<div>`. That's the "lightest" form of
+> markup that is built into ikiwiki itself.
+>
+> Alternatively^2, some different hook (I think [[plugins/typography]]
+> might use the right one?) could interpret an ad-hoc syntax and
+> turn it into a `<div>` either before or after `htmlize` processing.
+> However, that would be adding an extra layer of syntax for your
+> users to keep track of. --[[smcv]]

a weird authentication bug
diff --git a/doc/bugs/cannot_login.mdwn b/doc/bugs/cannot_login.mdwn
new file mode 100644
index 0000000..4574fbe
--- /dev/null
+++ b/doc/bugs/cannot_login.mdwn
@@ -0,0 +1,37 @@
+I can't seem to login to ikiwiki sites reliably anymore.
+
+I am not sure what is going on. It affects this wiki and the git-annex
+wiki. I am editing this through the anonymous git push interface.
+
+OpenID is failing on me. That is, sometimes it works, sometimes it
+doesn't. For example, while writing this, I clicked the "Preferences"
+link and I seemed to have been logged in automatically without
+problem, even though I previously *tried* to login and failed with an
+error similar to [[bugs/Error:_OpenID_failure:_time_bad_sig:]], which
+of course I cannot reproduce anymore on ikiwiki.info now:
+
+    Error: OpenID failure: time_bad_sig: Return_to signature is not
+    valid.
+
+I *can* still reproduce this on the git-annex wiki, however, which is
+odd. This *could* be because the OpenID host is screwing up, as I am
+not directly responsible for that box anymore... but then why would it
+work on one wiki and not the other?
+
+But worse, I cannot login with my regular non-OpenID user, which I
+started using more regularly now. When I type the wrong password, the
+login form gives me "Invalid entry" next to the password field. But
+then if I do a password recall and reset my password, I get a
+different error:
+
+    Error: login failed, perhaps you need to turn on cookies?
+
+That happens reliably on git-annex.branchable.com. ikiwiki.info seems
+to be more stable: i can eventually login. i can login to my personal
+wiki with OpenID fine. I can also login to branchable.com itself with
+openid without issues.
+
+So I guess the problem is mostly with git-annex.branchable.com? Not
+sure how to debug this further.
+
+Thanks. --[[anarcat]]

admonitions proposal
diff --git a/doc/todo/admonitions.mdwn b/doc/todo/admonitions.mdwn
new file mode 100644
index 0000000..3d5b7f1
--- /dev/null
+++ b/doc/todo/admonitions.mdwn
@@ -0,0 +1,25 @@
+In the [MoinMoin wiki][], there is this neat little hack called
+[Admonitions][] that basically create a `<div>` block with a specific
+style out of a certain section of the text.
+
+I couldn't find a way to do this easily in Ikiwiki. On the one hand,
+there is no easy way to create div blocks with arbitrary styles (which
+is basically what MoinMoin admonitions are). On the other hand, there
+are no neat little logos in stylesheets like there are in Moinmoin
+either.
+
+It would be great to see this implemented in Ikiwiki. Now, I know I
+can make a `<div>` myself, but I am not sure we should encourage users
+to inject arbitrary HTML in ikiwiki pages. And even then, we should
+add adminition CSS classes to make that easier to use.
+
+Ideally, Ikiwiki would support Pandoc or Github-style fenced blocks
+and could abuse those to allow arbitrary styles (and markup!) to kick
+in. The [[ikiwiki/directive/format]] directive could also be used, I
+guess, but I dislike how it requires all those brackets and quotes and
+bangs and all...
+
+-- [[anarcat]]
+
+[MoinMoin wiki]: https://moinmo.in/
+[Admonitions]: https://moinmo.in/HelpOnAdmonitions

Arguing more
diff --git a/doc/themes/discussion.mdwn b/doc/themes/discussion.mdwn
index d8241a8..1c0dd91 100644
--- a/doc/themes/discussion.mdwn
+++ b/doc/themes/discussion.mdwn
@@ -35,6 +35,12 @@ links to the actual theme. -- [[anarcat]]
 >>> version of `page.tmpl` containing only the features you personally
 >>> need, but the `page.tmpl` in ikiwiki should be comprehensive. --[[smcv]]
 
+>>>> I've tried to make the least changes possible in [this page.tmpl file](https://notabug.org/iikb/ikiwiki-theme-bootstrap/raw/master/templates/page.tmpl), but I couldn't overcome the suckness of bootstrap itself.
+>>>> I am aware of alternatives to bootstrap, but it seems that every one of them would require some changes in the `page.tmpl` to work as expected.
+>>>> I think it is realistic to have a bootstrap (or other superb, fantastic css frame*lazy*work) without a `page.tmpl`,
+>>>> but I also think there should be other way around the chaos of each and every [[available theme|theme_market]] having it's own installing proccess.
+>>>> Other argument I have is: could we have a theme-contrib, like the [[plugins]] have? This would require the mantainer to implement the new features in their themes.
+
 ---
 
 I have a question.

Added systemd for nginx
diff --git a/doc/tips/dot_cgi.mdwn b/doc/tips/dot_cgi.mdwn
index a33c8f3..3fc4048 100644
--- a/doc/tips/dot_cgi.mdwn
+++ b/doc/tips/dot_cgi.mdwn
@@ -82,6 +82,32 @@ made into a startup script in `init.d`. You may also need to make this file writ
 
     chmod a+w /tmp/fcgi.socket
 
+If you have [systemd](https://en.wikipedia.org/wiki/Systemd), you may use a service file like so:
+
+Edit/create a service file (in Debian it would be: `sudo vim /lib/systemd/system/ikiwiki.service`
+
+Content of `ikiwiki.service`:
+
+    [Unit]
+    Description=Ikiwiki fcgi socket wrap
+    After=network.target
+    
+    [Service]
+    Type=simple
+    User=www-data
+    Group=www-data
+    ExecStart=/usr/bin/spawn-fcgi -s /tmp/fcgi.socket -n -- /usr/sbin/fcgiwrap
+    
+    [Install]
+    WantedBy=multi-user.target
+
+Then run:
+
+    # This enables the service at startup
+    sudo systemctl enable ikiwiki.service
+    # This attempts to start the service
+    sudo systemctl start ikiwiki.service
+
 Then you need an nginx config plugged in that wrapper. Here's an
 example virtual host configuration:
 

diff --git a/doc/bugs/Anon_edit_caused_lock_out_on_entire_site_.mdwn b/doc/bugs/Anon_edit_caused_lock_out_on_entire_site_.mdwn
new file mode 100644
index 0000000..dc79bba
--- /dev/null
+++ b/doc/bugs/Anon_edit_caused_lock_out_on_entire_site_.mdwn
@@ -0,0 +1,53 @@
+Probably caused by something misconfigured about the [[plugins/comments]] plugin.
+
+---
+
+## Config
+
+My setup file:
+
+    # comments plugin
+    # PageSpec of pages where comments are allowed
+    comments_pagespec: forum/* or blog/posts/* or tarefa/*
+    # PageSpec of pages where posting new comments is not allowed
+    comments_closed_pagespec: ''
+    # Base name for comments, e.g. "comment_" for pages like "sandbox/comment_12"
+    comments_pagename: comment_
+    # Interpret directives in comments?
+    #comments_allowdirectives: 0
+    # Allow anonymous commenters to set an author name?
+    comments_allowauthor: 1
+    # commit comments to the VCS
+    comments_commit: 1
+    # Restrict formats for comments to (no restriction if empty)
+    comments_allowformats: mdwn txt
+
+The `moderatedcomments` plugins is **not** enabled
+
+The `anonok` plugin is **not** enabled
+
+---
+
+## Steps
+
+I've tried to place a comment clicking in the obvious [Add a comment](https://dev.iikb.org/ikiwiki.cgi?do=comment&page=forum%2FTema_bootstrap) in a [forum post](https://dev.iikb.org/forum/Tema_bootstrap/).
+
+I've not signed in because the *sign in* page didn't come up, instead a simple `(You might want to Signin first?)` showed up, which I've haven't read and commented away.
+
+---
+
+## Results
+
+As a consequence of that, the user '' - that's a null character, have somehow logged in and it seems that there is no way to [log it out](https://dev.iikb.org/ikiwiki.cgi?do=prefs).
+
+None of this phantom user edits are being commited - this [blog post](https://dev.iikb.org/blog/posts/Bug_severo_neste_site/) was made with that user logged in via web.
+
+It seems I can't log out from nowhere. I've rebuild the wiki from the command line and restarted the nginx server, the phantom user remains logged in and open to anyone willing to edit away the wiki.
+
+---
+
+## Conclusion
+
+If I wanted to do a totally anonnymous wiki, this would be the best setup ever.
+
+For [this particular installation](https://dev.iikb.org), that's not the case.

Document new feature.
diff --git a/doc/plugins/contrib/compile.mdwn b/doc/plugins/contrib/compile.mdwn
index 564f7f6..7527f26 100644
--- a/doc/plugins/contrib/compile.mdwn
+++ b/doc/plugins/contrib/compile.mdwn
@@ -91,6 +91,7 @@ using python-like string formatting, and described in the setup options section.
   advertised).
 - `template`: Name of the template to use (if set, the `source` option is
   irrelevant).
+- `var_*`: Any argument with a name starting with ``var_`` is transmitted to the template. For instance, if directive has argument ``var_foo=bar``, then the template will have a variable named ``foo``, and ``<TMPL_VAR FOO>`` will be replaced by ``bar``.
 
 ### Extensions
 

clarify that theme and css is not only to change stylesheets, but the look in general
diff --git a/doc/examples.mdwn b/doc/examples.mdwn
index 19631ad..c772dc0 100644
--- a/doc/examples.mdwn
+++ b/doc/examples.mdwn
@@ -9,4 +9,4 @@ Each example is contained in its own subdirectory; just copy the source
 files into your wiki to start using one of the examples.
 
 The [[tips]] page has some other ideas for ways to use ikiwiki, and the
-[[css_market]] and [[theme market|themes]] has some example stylesheets to change ikiwiki's look.
+[[css_market]] and [[theme market|themes]] explain how to change ikiwiki's look.

link to localstyle after a user struggled for hours to figure out exactly that
diff --git a/doc/css_market.mdwn b/doc/css_market.mdwn
index 65e2f5c..d41a4a3 100644
--- a/doc/css_market.mdwn
+++ b/doc/css_market.mdwn
@@ -4,6 +4,9 @@ User contributed stylesheet files for ikiwiki. Unless otherwise noted,
 these style sheets can be installed by copying them into your wiki's source
 dir with a filename of `local.css`.
 
+Note that if you enable the [[plugins/localstyle]] plugin, you can also
+create stylesheets that affect only certain parts of the wiki.
+
 Some of stylesheets have developed into fullfledged [[themes]] that are
 included in ikiwiki for easy use.
 

explain why multiple page.tmpl is a showstopper for upstream even if not for local themes
diff --git a/doc/themes/discussion.mdwn b/doc/themes/discussion.mdwn
index d7bd8d6..d8241a8 100644
--- a/doc/themes/discussion.mdwn
+++ b/doc/themes/discussion.mdwn
@@ -21,6 +21,20 @@ links to the actual theme. -- [[anarcat]]
 
 >> Would you reconsider? I've made [[this bootstrap theme|/forum/bootstrap_theme]] that works within the theme plugin without changing the `templatedir` configuration option. It seems that the `page.tmpl` I have in the subfolder `templates` takes precedence. Not sure what you meant by "two versions of page.tmpl", though. -- [[desci]]
 
+>>> The reason we don't want individual themes shipped with ikiwiki
+>>> to have to include their own `page.tmpl` is that when we add new
+>>> features (such as new plugins) to the ikiwiki core, if those features
+>>> require a `page.tmpl` change, we don't want to have to add them to
+>>> multiple variations of `page.tmpl`. This would either lead to
+>>> increased maintenance work (repeating ourselves), or theme-dependent
+>>> feature availability like what happens in Wordpress (for instance
+>>> imagine if `osm` only worked with Bootstrap and `sidebar` only worked
+>>> with Actiontabs - you wouldn't be able to have both).
+>>>
+>>> If you maintain your own local theme, you're welcome to maintain a
+>>> version of `page.tmpl` containing only the features you personally
+>>> need, but the `page.tmpl` in ikiwiki should be comprehensive. --[[smcv]]
+
 ---
 
 I have a question.

diff --git a/doc/users/desci.mdwn b/doc/users/desci.mdwn
index f3592cc..dce4ea4 100644
--- a/doc/users/desci.mdwn
+++ b/doc/users/desci.mdwn
@@ -10,21 +10,15 @@ A plugin to add facebook spyware to your ikiwiki: [[plugins/contrib/opengraph/]]
 
 ---
 
+# Ikiwiki Themes
+
+A theme to add [bootstrap 3](https://getbootstrap.com) to ikiwiki without overhauling the installation: [[forum/bootstrap_theme]]
+
+---
+
 # Ikiwiki Sites
 
 ## Currently online:
 
 * <https://dev.iikb.org>
 * <https://dev.iikb.xyz> (proxy_pass)
-
-## Offline:
-
-Sites I **was** using Ikiwiki with the [[bootstrap 3 theme|/theme_market]]:
-
-* *<https://hi.ato.br>*
-* *<https://capoeira.li/blog>*
-* *<http://dissertosradicais.tem.blog.br>*
-* *<http://epelaspracasnaoteranome.tem.blog.br>*
-* *<http://iuri.tem.blog.br>*
-* *<http://mim.tem.blog.br>*
-* *<http://piratas.xyz>*

Updated link
diff --git a/doc/tips/bootstrap_themes_evaluation.mdwn b/doc/tips/bootstrap_themes_evaluation.mdwn
index 9308a64..77849db 100644
--- a/doc/tips/bootstrap_themes_evaluation.mdwn
+++ b/doc/tips/bootstrap_themes_evaluation.mdwn
@@ -39,7 +39,7 @@ As for the [[theme_market]] page, since the modifications didn't provide much in
 
 ---
 
-There you go, I've provided a minimalistic [Bootstrap 3 Template](https://notabug.org/iikb/ikiwiki-theme-bootstrap) that should behave the proper way (tm) and it's easy as cloning the repository on `/usr/share/ikiwiki/themes/boostrap` and setting `theme: bootstrap`.
+There you go, I've provided a minimalistic [[Bootstrap 3 Template|/forum/bootstrap_theme]] that should behave the proper way (tm) and it's easy as cloning the repository on `/usr/share/ikiwiki/themes/boostrap` and setting `theme: bootstrap`.
 
 I've saved an [example on the wayback machine](https://web.archive.org/web/20160409044511/https://dev.iikb.org/forum/Tema_bootstrap/), because I will continue to improve that theme and the idea now is to make multiple variations of it, so the user has a choice. For example, changing the navbar from black to white requires some bootstrap specific changes, so I'll probably make another theme just for that.
 

Updated link
diff --git a/doc/themes/discussion.mdwn b/doc/themes/discussion.mdwn
index 39b9264..d7bd8d6 100644
--- a/doc/themes/discussion.mdwn
+++ b/doc/themes/discussion.mdwn
@@ -19,7 +19,7 @@ links to the actual theme. -- [[anarcat]]
 > so the page.tmpl could use that to do different things if the boostrap
 > theme was enabled. --[[Joey]]
 
->> Would you reconsider? I've made [this bootstrap theme](https://notabug.org/iikb/ikiwiki-theme-bootstrap/releases) that works within the theme plugin without changing the `templatedir` configuration option. It seems that the `page.tmpl` I have in the subfolder `templates` takes precedence. Not sure what you meant by "two versions of page.tmpl", though. -- [[desci]]
+>> Would you reconsider? I've made [[this bootstrap theme|/forum/bootstrap_theme]] that works within the theme plugin without changing the `templatedir` configuration option. It seems that the `page.tmpl` I have in the subfolder `templates` takes precedence. Not sure what you meant by "two versions of page.tmpl", though. -- [[desci]]
 
 ---
 
@@ -31,8 +31,6 @@ I put `.pm` plugins on `~/.ikiwiki/Ikiwiki/Plugin` and it works well.
 
 How would I go about not tampering with the root filesystem to install a theme?
 
---[[desci]]
-
 Also, I have another question:
 
 I have a complex theme I'm working on, and it doesn't even have a `style.css`, because it is about editing `.tmpl` files and relying on the bootstrap files, so I want to know if the theme plugin will understand this structure:

Edited old sentence to reference the forum
diff --git a/doc/todo/compatible_templates.mdwn b/doc/todo/compatible_templates.mdwn
index eef2bd3..687515d 100644
--- a/doc/todo/compatible_templates.mdwn
+++ b/doc/todo/compatible_templates.mdwn
@@ -25,7 +25,9 @@ I think it was anarcat who had the patches
 > someone else ported bootstrap4 to ikiwiki (see
 > [ikistrap][]). -- [[anarcat]]
 
-> The only standard i know of for the web that actually worked is html5. I've started [yet another bootstrap template](https://web.archive.org/web/20160409044511/https://dev.iikb.org/forum/Tema_bootstrap/). I want to get it right the way bootstrap proposes in order to form a base theme to make many others. Bootstrap sucks, by the way, I am already working on other frameworks. --[[desci]]
+---
+
+I've started [yet another bootstrap theme](https://notabug.org/iikb/ikiwiki-theme-bootstrap). The main reason being because I wanted a theme that actually worked within the [[theme plugin|/plugins/theme]] without changing anything else, and [[I've made it|/forum/bootstrap_theme]]. --[[desci]]
 
 [ikistrap]: https://github.com/gsliepen/ikistrap
 [bootstrap theme]: https://anarc.at/blog/2015-09-09-bootstrap/

diff --git a/doc/forum/bootstrap_theme.mdwn b/doc/forum/bootstrap_theme.mdwn
new file mode 100644
index 0000000..949aef5
--- /dev/null
+++ b/doc/forum/bootstrap_theme.mdwn
@@ -0,0 +1,17 @@
+I've edited a lot of pages with redundant questions, so I will centralize this right here.
+
+After reading a lot until I've found the [[/forum/debconf13_ikiwiki_bof]], and I saw there was a *welcome* for a generic bootstrap theme, so I've delivered.
+
+The 'yet another bootstrap theme' has it's source code on [notabug](https://notabug.org/iikb/ikiwiki-theme-bootstrap).
+
+The installation is like I expected any other theme to be:
+
+* [Untar](https://notabug.org/iikb/ikiwiki-theme-bootstrap/archive/1.0.0.25.tar.gz) or [unzip](https://notabug.org/iikb/ikiwiki-theme-bootstrap/archive/1.0.0.25.zip) the [release files](https://notabug.org/iikb/ikiwiki-theme-bootstrap/releases) into `/usr/share/ikiwiki/themes/bootstrap/`;
+* Active the theme `bootstrap` in the setup file or web setup like [[the manual said|/plugins/theme]];
+* Rebuild the wiki if it doesn't automatically and the site should look like [this](https://web.archive.org/web/20160409044511/https://dev.iikb.org/forum/Tema_bootstrap/).
+
+The [current release](https://notabug.org/iikb/ikiwiki-theme-bootstrap/archive/1.0.0.25.tar.gz) has less than the basics, however it should work out of the box and without modifying anything else, the template files that are tampered with are contained inside the theme folder.
+
+It also shouldn't use external *cdn*s, it does currently use [my own cdn](https://cdn.iik.org) but no one should rely on it so I'm moving the files inside the git tree so it will be auto contained.
+
+It is available in the [[theme_market]] already.

Asked Joey to reconsider
diff --git a/doc/themes/discussion.mdwn b/doc/themes/discussion.mdwn
index 5e5362e..39b9264 100644
--- a/doc/themes/discussion.mdwn
+++ b/doc/themes/discussion.mdwn
@@ -19,6 +19,8 @@ links to the actual theme. -- [[anarcat]]
 > so the page.tmpl could use that to do different things if the boostrap
 > theme was enabled. --[[Joey]]
 
+>> Would you reconsider? I've made [this bootstrap theme](https://notabug.org/iikb/ikiwiki-theme-bootstrap/releases) that works within the theme plugin without changing the `templatedir` configuration option. It seems that the `page.tmpl` I have in the subfolder `templates` takes precedence. Not sure what you meant by "two versions of page.tmpl", though. -- [[desci]]
+
 ---
 
 I have a question.

Added yet another bootstrap theme
diff --git a/doc/theme_market.mdwn b/doc/theme_market.mdwn
index d7ebd1c..dd3b073 100644
--- a/doc/theme_market.mdwn
+++ b/doc/theme_market.mdwn
@@ -12,6 +12,8 @@ Feel free to add your own [[theme|themes]] here, but first consider writing a si
 
 * **[Bootstrap theme](http://anonscm.debian.org/gitweb/?p=users/jak/website.git;a=summary)**, contributed by [JAK LINUX](http://jak-linux.org/about/), based on [Twitter Bootstrap](http://twitter.github.com/bootstrap/), [modifications available](https://anarc.at/blog/2015-09-09-bootstrap/) from [[anarcat]] as well
 
+  * [Yet another bootstrap theme](https://notabug.org/iikb/ikiwiki-theme-bootstrap), this one can be used like a regular theme by placing [the theme files](https://notabug.org/iikb/ikiwiki-theme-bootstrap/archive/1.0.0.25.zip) on `/usr/share/ikiwiki/themes/bootstrap/` and changing the `theme` configuration to `boostrap`.
+
 * **[Bootstrap 3](https://github.com/ramseydsilva/ikiwiki-bootstrap-theme)**, contributed by [[ramsey]], based on [Twitter Bootstrap 3](http://getbootstrap.com). [Example](http://bootstrap-ramseydsilva.wiki.orangeseeds.org). This template has been forked and modified in many ways:
 
   * Modification for [dequis.org](https://github.com/dequis/ikiwiki-bootstrap-theme/tree/dequis.org). [Example](http://bootstrap-dequis.wiki.orangeseeds.org).
@@ -22,5 +24,6 @@ Feel free to add your own [[theme|themes]] here, but first consider writing a si
 
   * And one more **[Bootstrap 3](https://github.com/tgpfeiffer/ikiwiki-bootstrap-template)** theme (can't you guys get along already?!), contributed by tgpfeiffer, this one shipping a copy of the bootstrap files. [Example](http://bootstrap-tgpfeiffer.wiki.orangeseeds.org).
 
+
 * **[Ikistrap](https://github.com/gsliepen/ikistrap)**, contributed by gsliepen, based on Bootstrap 4.
 

Added question
diff --git a/doc/themes/discussion.mdwn b/doc/themes/discussion.mdwn
index 88a1e38..5e5362e 100644
--- a/doc/themes/discussion.mdwn
+++ b/doc/themes/discussion.mdwn
@@ -57,4 +57,8 @@ I have a complex theme I'm working on, and it doesn't even have a `style.css`, b
         └── whatever.tmpl
 ```
 
---[[desci]]
+**Edit:** no, it doesn't. When i change theme in the config to `my-theme`, the engine only uses the `templates` subfolder under `theme/my-theme`, and not `basewiki`. So the workaround is doing like [IkiStrap](https://github.com/gsliepen/ikistrap) proposed, suggesting the user to alter the `underlaydir` and `templatedir` configs instead of choosing a theme via the old fashioned `theme` config.
+
+This feels more like an overhaul than a theme for me, could we clarify what is a theme, a template, an overhaul, a change to the look and feel, a change to the frontend, a change to the design, etc.?
+
+-- [[desci]]

There's also a config file option.
diff --git a/doc/plugins/typography.mdwn b/doc/plugins/typography.mdwn
index 9ff6c4f..4b274d1 100644
--- a/doc/plugins/typography.mdwn
+++ b/doc/plugins/typography.mdwn
@@ -7,6 +7,8 @@ plain ASCII punctuation characters into ``smart'' typographic punctuation HTML
 entities. To use it, you need to have the [[!cpan Text::Typography]] module
 installed.
 
-This plugin has a configuration option. To change the attributes,
-set `--typographyattributes=whatever`. See the documentation for
-[[!cpan Text::Typography]] for available attributes.
+This plugin has a configuration option. To change the attributes, set
+`--typographyattributes=whatever`.  Alternatively, set
+`typograph_attributes: whatever` in your config file.  The default is
+`3`.  See the documentation for [[!cpan Text::Typography]] for available
+attributes.

Marketing
diff --git a/doc/todo/compatible_templates.mdwn b/doc/todo/compatible_templates.mdwn
index a47f4ba..eef2bd3 100644
--- a/doc/todo/compatible_templates.mdwn
+++ b/doc/todo/compatible_templates.mdwn
@@ -25,6 +25,8 @@ I think it was anarcat who had the patches
 > someone else ported bootstrap4 to ikiwiki (see
 > [ikistrap][]). -- [[anarcat]]
 
+> The only standard i know of for the web that actually worked is html5. I've started [yet another bootstrap template](https://web.archive.org/web/20160409044511/https://dev.iikb.org/forum/Tema_bootstrap/). I want to get it right the way bootstrap proposes in order to form a base theme to make many others. Bootstrap sucks, by the way, I am already working on other frameworks. --[[desci]]
+
 [ikistrap]: https://github.com/gsliepen/ikistrap
 [bootstrap theme]: https://anarc.at/blog/2015-09-09-bootstrap/
 [custom theme]: http://anarcat.ath.cx/night_city/README/

Delivering what I've promised
diff --git a/doc/tips/bootstrap_themes_evaluation.mdwn b/doc/tips/bootstrap_themes_evaluation.mdwn
index 8f41a60..9308a64 100644
--- a/doc/tips/bootstrap_themes_evaluation.mdwn
+++ b/doc/tips/bootstrap_themes_evaluation.mdwn
@@ -36,3 +36,11 @@ The webdev collective has just met again and the plan to make multiple ikiwiki b
 As for the [[theme_market]] page, since the modifications didn't provide much innovation, mine included, I've [edited the page](http://source.ikiwiki.branchable.com/?p=source.git;a=commit;h=b18ae270ac7b93fe51f83bd7dc885d068165e407), see if it seems cleaner now.
 
 --[[desci]]
+
+---
+
+There you go, I've provided a minimalistic [Bootstrap 3 Template](https://notabug.org/iikb/ikiwiki-theme-bootstrap) that should behave the proper way (tm) and it's easy as cloning the repository on `/usr/share/ikiwiki/themes/boostrap` and setting `theme: bootstrap`.
+
+I've saved an [example on the wayback machine](https://web.archive.org/web/20160409044511/https://dev.iikb.org/forum/Tema_bootstrap/), because I will continue to improve that theme and the idea now is to make multiple variations of it, so the user has a choice. For example, changing the navbar from black to white requires some bootstrap specific changes, so I'll probably make another theme just for that.
+
+--[[desci]]

Ok now I've got it right
diff --git a/doc/themes/discussion.mdwn b/doc/themes/discussion.mdwn
index 1dba08a..88a1e38 100644
--- a/doc/themes/discussion.mdwn
+++ b/doc/themes/discussion.mdwn
@@ -40,16 +40,17 @@ I have a complex theme I'm working on, and it doesn't even have a `style.css`, b
 └── my-theme/
     ├── basewiki/
     │   ├── bootstrap/
-    │   │   └── bootstrap.min.css
-    │   ├── js/
-    │   │   ├── bootstrap.js
-    │   │   └── bootstrap.min.js
-    │   ├── fonts/
-    │   │   ├── glyphicons-halflings-regular.eot
-    │   │   ├── glyphicons-halflings-regular.svg
-    │   │   ├── glyphicons-halflings-regular.ttf
-    │   │   ├── glyphicons-halflings-regular.woff
-    │   │   └── glyphicons-halflings-regular.woff2
+    │   │   ├── css/
+    │   │   │   └── bootstrap.min.css
+    │   │   ├── js/
+    │   │   │   ├── bootstrap.js
+    │   │   │   └── bootstrap.min.js
+    │   │   └── fonts/
+    │   │       ├── glyphicons-halflings-regular.eot
+    │   │       ├── glyphicons-halflings-regular.svg
+    │   │       ├── glyphicons-halflings-regular.ttf
+    │   │       ├── glyphicons-halflings-regular.woff
+    │   │       └── glyphicons-halflings-regular.woff2
     │   └── index.mdwn
     └── templates/
         ├── page.tmpl

The structure was all wrong
diff --git a/doc/themes/discussion.mdwn b/doc/themes/discussion.mdwn
index 98d8056..1dba08a 100644
--- a/doc/themes/discussion.mdwn
+++ b/doc/themes/discussion.mdwn
@@ -38,18 +38,19 @@ I have a complex theme I'm working on, and it doesn't even have a `style.css`, b
 ```
 /usr/share/ikiwiki/themes/
 └── my-theme/
-    ├── bootstrap/
-    │   └── bootstrap.min.css
-    ├── js/
-    │   ├── bootstrap.js
-    │   └── bootstrap.min.js
-    ├── fonts/
-    │   ├── glyphicons-halflings-regular.eot
-    │   ├── glyphicons-halflings-regular.svg
-    │   ├── glyphicons-halflings-regular.ttf
-    │   ├── glyphicons-halflings-regular.woff
-    │   └── glyphicons-halflings-regular.woff2
-    ├── index.mdwn
+    ├── basewiki/
+    │   ├── bootstrap/
+    │   │   └── bootstrap.min.css
+    │   ├── js/
+    │   │   ├── bootstrap.js
+    │   │   └── bootstrap.min.js
+    │   ├── fonts/
+    │   │   ├── glyphicons-halflings-regular.eot
+    │   │   ├── glyphicons-halflings-regular.svg
+    │   │   ├── glyphicons-halflings-regular.ttf
+    │   │   ├── glyphicons-halflings-regular.woff
+    │   │   └── glyphicons-halflings-regular.woff2
+    │   └── index.mdwn
     └── templates/
         ├── page.tmpl
         └── whatever.tmpl

Forgot to add the main folder
diff --git a/doc/themes/discussion.mdwn b/doc/themes/discussion.mdwn
index 2ac7576..98d8056 100644
--- a/doc/themes/discussion.mdwn
+++ b/doc/themes/discussion.mdwn
@@ -36,6 +36,7 @@ Also, I have another question:
 I have a complex theme I'm working on, and it doesn't even have a `style.css`, because it is about editing `.tmpl` files and relying on the bootstrap files, so I want to know if the theme plugin will understand this structure:
 
 ```
+/usr/share/ikiwiki/themes/
 └── my-theme/
     ├── bootstrap/
     │   └── bootstrap.min.css