Merge remote-tracking branch 'anarcat/dev/proxy-utf8-fail'
authorJoey Hess <joey@kitenet.net>
Tue, 25 Feb 2014 04:13:36 +0000 (00:13 -0400)
committerJoey Hess <joey@kitenet.net>
Tue, 25 Feb 2014 04:13:36 +0000 (00:13 -0400)
64 files changed:
.gitignore
IkiWiki.pm
IkiWiki/CGI.pm
IkiWiki/Plugin/aggregate.pm
IkiWiki/Plugin/attachment.pm
IkiWiki/Plugin/editpage.pm
IkiWiki/Plugin/edittemplate.pm
IkiWiki/Plugin/git.pm
IkiWiki/Plugin/inline.pm
IkiWiki/Plugin/mdwn.pm
IkiWiki/Plugin/openid.pm
IkiWiki/Plugin/pinger.pm
IkiWiki/Plugin/po.pm
IkiWiki/Plugin/template.pm
debian/changelog
debian/copyright
doc/bugs/Spurious___60__p__62___elements_added_to_tags_in_inliine_pages.mdwn
doc/bugs/assumes___34__git_push_origin__34___is_sufficient.mdwn [new file with mode: 0644]
doc/bugs/can__39__t_upload_a_simple_png_image:_prohibited_by_allowed__95__attachments___40__file_MIME_type_is_application__47__octet-stream....mdwn
doc/bugs/crashes_in_the_python_proxy_even_if_disabled.mdwn
doc/bugs/do_not_let_big_brother_spy_on_our_users_on_login.mdwn
doc/bugs/editing_gitbranch_template_is_really_slow.mdwn [new file with mode: 0644]
doc/bugs/error_handlers_with_gettext_can_clobber___36____64__.mdwn [new file with mode: 0644]
doc/bugs/listdirectives_doesn__39__t_register_a_link.mdwn
doc/bugs/pages_under_templates_are_invalid.mdwn
doc/bugs/preprocessing_loop_control_too_tight.mdwn
doc/bugs/syslog_fails_with_non-ASCII_wikinames.mdwn
doc/bugs/template__95__syntax_test_is_incomplete.mdwn [new file with mode: 0644]
doc/bugs/template_creation_error.mdwn
doc/forum/How_can_I_invert_the_banned__95__user_check__63__.mdwn [new file with mode: 0644]
doc/forum/formating:_how_to_align_text_to_the_right.mdwn
doc/ikiwiki/directive/edittemplate.mdwn
doc/ikiwiki/directive/edittemplate/discussion.mdwn [new file with mode: 0644]
doc/ikiwikiusers.mdwn
doc/news/version_3.20130710.mdwn [deleted file]
doc/news/version_3.20140125.mdwn [new file with mode: 0644]
doc/plugins/contrib/nimble.mdwn [new file with mode: 0644]
doc/sandbox.mdwn
doc/sandbox/New_blog_entry.mdwn [new file with mode: 0644]
doc/templates/gitbranch.mdwn
doc/tips/Hosting_Ikiwiki_and_master_git_repository_on_different_machines.mdwn
doc/todo/Option_linktext_for_pagestats_directive.mdwn
doc/todo/bitcoin_URI_scheme.mdwn [new file with mode: 0644]
doc/todo/edittemplate_should_support_uuid__44___date_variables.mdwn
doc/todo/expose_html_language_and_direction.mdwn
doc/todo/missingparents.pm.mdwn
doc/todo/support_linking_to_cgit.mdwn
doc/users/holger.mdwn [new file with mode: 0644]
doc/users/smcv.mdwn
doc/users/smcv/yesplease.mdwn [new file with mode: 0644]
icons/aol.svg [new file with mode: 0644]
icons/livejournal.svg [new file with mode: 0644]
icons/verisign.svg [new file with mode: 0644]
t/git.t
t/syslog.t [new file with mode: 0644]
t/template_syntax.t
underlays/openid-selector/ikiwiki/openid/aol.png [new file with mode: 0644]
underlays/openid-selector/ikiwiki/openid/goa-account-flickr.png [new file with mode: 0644]
underlays/openid-selector/ikiwiki/openid/goa-account-google.png [new file with mode: 0644]
underlays/openid-selector/ikiwiki/openid/goa-account-yahoo.png [new file with mode: 0644]
underlays/openid-selector/ikiwiki/openid/livejournal.png [new file with mode: 0644]
underlays/openid-selector/ikiwiki/openid/openid-jquery.js
underlays/openid-selector/ikiwiki/openid/verisign.png [new file with mode: 0644]
underlays/openid-selector/ikiwiki/openid/wordpress.png [new file with mode: 0644]

index f8991a63dcc3100130f9b575cba36a568184df6d..8528fe9bed7336175e4315f610c96a2d6880af6a 100644 (file)
@@ -9,6 +9,7 @@ ikiwiki.out
 ikiwiki-transition.out
 ikiwiki-calendar.out
 pm_to_blib
+/MYMETA.json
 /MYMETA.yml
 *.man
 /po/cover_db
index b7080bb0b3ff14f1af78dd1633a1f05ed722d6d6..e5da04a3bb86d8aa47d96cac3df679623ad707ee 100644 (file)
@@ -527,6 +527,14 @@ sub getsetup () {
                safe => 0, # hooks into perl module internals
                rebuild => 0,
        },
+       useragent => {
+               type => "string",
+               default => undef,
+               example => "Wget/1.13.4 (linux-gnu)",
+               description => "set custom user agent string for outbound HTTP requests e.g. when fetching aggregated RSS feeds",
+               safe => 0,
+               rebuild => 0,
+       },
 }
 
 sub defaultconfig () {
@@ -735,6 +743,7 @@ sub debug ($) {
 }
 
 my $log_open=0;
+my $log_failed=0;
 sub log_message ($$) {
        my $type=shift;
 
@@ -745,9 +754,18 @@ sub log_message ($$) {
                        Sys::Syslog::openlog('ikiwiki', '', 'user');
                        $log_open=1;
                }
-               return eval {
-                       Sys::Syslog::syslog($type, "[$config{wikiname}] %s", join(" ", @_));
+               eval {
+                       # keep a copy to avoid editing the original config repeatedly
+                       my $wikiname = $config{wikiname};
+                       utf8::encode($wikiname);
+                       Sys::Syslog::syslog($type, "[$wikiname] %s", join(" ", @_));
                };
+                if ($@) {
+                    print STDERR "failed to syslog: $@" unless $log_failed;
+                    $log_failed=1;
+                    print STDERR "@_\n";
+                }
+                return $@;
        }
        elsif (! $config{cgi}) {
                return print "@_\n";
@@ -1490,7 +1508,7 @@ sub preprocess ($$$;$$) {
                                        push @params, $val, '';
                                }
                        }
-                       if ($preprocessing{$page}++ > 3) {
+                       if ($preprocessing{$page}++ > 8) {
                                # Avoid loops of preprocessed pages preprocessing
                                # other pages that preprocess them, etc.
                                return "[[!$command <span class=\"error\">".
@@ -2301,6 +2319,7 @@ sub useragent () {
        return LWP::UserAgent->new(
                cookie_jar => $config{cookiejar},
                env_proxy => 1,         # respect proxy env vars
+               agent => $config{useragent},
        );
 }
 
index 5baa6c1798ef02e1f45680daa032da17674fafb0..c0d8f598b5f882b27bd2d5671d476aa5164a812b 100644 (file)
@@ -351,7 +351,8 @@ sub cgi_getsession ($) {
                        { FileName => "$config{wikistatedir}/sessions.db" })
        };
        if (! $session || $@) {
-               error($@." ".CGI::Session->errstr());
+               my $error = $@;
+               error($error." ".CGI::Session->errstr());
        }
        
        umask($oldmask);
index 28c445913f436e8ee7269fb1b3eea6ca35351bab..fbf88c62738d783c210d27cf6aa57c1b81c71fef 100644 (file)
@@ -553,7 +553,9 @@ sub aggregate (@) {
                        };
                }
                if ($@) {
-                       $feed->{message}=gettext("feed crashed XML::Feed!")." ($@)";
+                       # gettext can clobber $@
+                       my $error = $@;
+                       $feed->{message}=gettext("feed crashed XML::Feed!")." ($error)";
                        $feed->{error}=1;
                        debug($feed->{message});
                        next;
@@ -675,7 +677,9 @@ sub write_page ($$$$$) {
                $template=template($feed->{template}, blind_cache => 1);
        };
        if ($@) {
-               print STDERR gettext("failed to process template:")." $@";
+               # gettext can clobber $@
+               my $error = $@;
+               print STDERR gettext("failed to process template:")." $error";
                return;
        }
        $template->param(title => $params{title})
index 83dd120f649ea13898ee9cc479bb576cb94043b7..d56dd18ad8ded90e3dd6f46598e7bc632359d4b5 100644 (file)
@@ -229,8 +229,10 @@ sub attachment_store {
                check_canattach($session, $final_filename, $tempfile);
        };
        if ($@) {
-               json_response($q, $form, $dest."/".$filename, $@);
-               error $@;
+               # save error in case called functions clobber $@
+               my $error = $@;
+               json_response($q, $form, $dest."/".$filename, $error);
+               error $error;
        }
 
        # Move the attachment into holding directory.
index d15607990db2412b8a14f281864f82f98b3cac7f..3047869c4a0ad4da75f715937b8fff185dc80970 100644 (file)
@@ -400,10 +400,12 @@ sub cgi_editpage ($$) {
                eval { writefile($file, $config{srcdir}, $content) };
                $config{cgi}=1;
                if ($@) {
+                       # save $@ in case a called function clobbers it
+                       my $error = $@;
                        $form->field(name => "rcsinfo", value => rcs_prepedit($file),
                                force => 1);
                        my $mtemplate=template("editfailedsave.tmpl");
-                       $mtemplate->param(error_message => $@);
+                       $mtemplate->param(error_message => $error);
                        $form->tmpl_param("message", $mtemplate->output);
                        $form->field("editcontent", value => $content, force => 1);
                        $form->tmpl_param("page_select", 0);
index c7f1e4fa7f7117660b5d89207a1795caec9fc6af..e3ce5e3d97437392c681f20f6c3a23b0b9690790 100644 (file)
@@ -130,9 +130,11 @@ sub filltemplate ($$) {
                $template=template("/".$template_page);
        };
        if ($@) {
+               # gettext can clobber $@
+               my $error = $@;
                # Indicate that the earlier preprocessor directive set 
                # up a template that doesn't work.
-               return "[[!edittemplate ".gettext("failed to process template:")." $@]]";
+               return "[[!edittemplate ".gettext("failed to process template:")." $error]]";
        }
 
        $template->param(name => $page);
index 77c0678bcbd8dfd32c13b164477ea899d0c9f38a..4b0e5a86d065fba816d58564dd0593209c9d3680 100644 (file)
@@ -609,7 +609,7 @@ sub rcs_commit_helper (@) {
        # So we should ignore its exit status (hence run_or_non).
        if (run_or_non('git', 'commit', '-m', $params{message}, '-q', @opts)) {
                if (length $config{gitorigin_branch}) {
-                       run_or_cry('git', 'push', $config{gitorigin_branch});
+                       run_or_cry('git', 'push', $config{gitorigin_branch}, $config{gitmaster_branch});
                }
        }
        
@@ -660,7 +660,9 @@ sub rcs_recentchanges ($) {
                my @pages;
                foreach my $detail (@{ $ci->{'details'} }) {
                        my $file = $detail->{'file'};
-                       my $efile = uri_escape_utf8($file);
+                       my $efile = join('/',
+                               map { uri_escape_utf8($_) } split('/', $file)
+                       );
 
                        my $diffurl = defined $config{'diffurl'} ? $config{'diffurl'} : "";
                        $diffurl =~ s/\[\[file\]\]/$efile/go;
index 0380bec3d6cd9948ec92229117ea3655212af59a..123dfd36489c8536450971c95267ef30261abcc9 100644 (file)
@@ -391,7 +391,9 @@ sub preprocess_inline (@) {
                                        blind_cache => 1);
                        };
                        if ($@) {
-                               error sprintf(gettext("failed to process template %s"), $params{template}.".tmpl").": $@";
+                               # gettext can clobber $@
+                               my $error = $@;
+                               error sprintf(gettext("failed to process template %s"), $params{template}.".tmpl").": $error";
                        }
                }
                my $needcontent=$raw || (!($archive && $quick) && $template->query(name => 'content'));
index 430194bffdcc6444f34036709d9dc3767187af85..014e78eea124604e249d35d42a6b9ccf6524c254 100644 (file)
@@ -92,8 +92,9 @@ sub htmlize (@) {
                                        $markdown_sub=\&Markdown::Markdown;
                                }
                                else {
+                                       my $error = $@;
                                        do "/usr/bin/markdown" ||
-                                               error(sprintf(gettext("failed to load Markdown.pm perl module (%s) or /usr/bin/markdown (%s)"), $@, $!));
+                                               error(sprintf(gettext("failed to load Markdown.pm perl module (%s) or /usr/bin/markdown (%s)"), $error, $!));
                                        $markdown_sub=\&Markdown::Markdown;
                                }
                        }
index d369e30c995277f8a5e7f5bccdd5cd17dbcea0aa..3b96e4b8e411c5f29afc25b58e15cdfd9f70121d 100644 (file)
@@ -238,7 +238,7 @@ sub getobj ($$) {
        my $ua;
        eval q{use LWPx::ParanoidAgent};
        if (! $@) {
-               $ua=LWPx::ParanoidAgent->new;
+               $ua=LWPx::ParanoidAgent->new(agent => $config{useragent});
        }
        else {
                $ua=useragent();
index fb0f3ba0aa9cf9676f95eaded1f4569504015c99..b2d54af8ac269cd63e95913073919cfd2b496052 100644 (file)
@@ -72,7 +72,7 @@ sub ping {
                my $ua;
                eval q{use LWPx::ParanoidAgent};
                if (!$@) {
-                       $ua=LWPx::ParanoidAgent->new;
+                       $ua=LWPx::ParanoidAgent->new(agent => $config{useragent});
                }
                else {
                        eval q{use LWP};
index 53e6af92f1db14c668f287724aed7b8b12c6f76a..6107a4a2252c256e715a3b0bd210eb28d45371b3 100644 (file)
@@ -346,6 +346,12 @@ sub pagetemplate (@) {
        if ($template->query(name => "lang_code")) {
                $template->param(lang_code => $lang_code);
        }
+       if ($template->query(name => "html_lang_code")) {
+               $template->param(html_lang_code => htmllangcode($lang_code));
+       }
+       if ($template->query(name => "html_lang_dir")) {
+               $template->param(html_lang_dir => htmllangdir($lang_code));
+       }
        if ($template->query(name => "lang_name")) {
                $template->param(lang_name => languagename($lang_code));
        }
@@ -857,6 +863,19 @@ sub lang ($) {
        return $master_language_code;
 }
 
+sub htmllangcode ($) {
+       (my $lang = shift) =~ tr/_/-/;
+       return $lang;
+}
+
+sub htmllangdir ($) {
+       my $lang = shift;
+       if ($lang =~ /^(ar|fa|he)/) {
+               return 'rtl';
+       }
+       return 'ltr';
+}
+
 sub islanguagecode ($) {
        my $code=shift;
 
@@ -1053,6 +1072,8 @@ sub otherlanguagesloop ($) {
                push @ret, {
                        url => urlto_with_orig_beautiful_urlpath(masterpage($page), $page),
                        code => $master_language_code,
+                       html_code => htmllangcode($master_language_code),
+                       html_dir => htmllangdir($master_language_code),
                        language => $master_language_name,
                        master => 1,
                };
@@ -1063,6 +1084,8 @@ sub otherlanguagesloop ($) {
                push @ret, {
                        url => urlto_with_orig_beautiful_urlpath($otherpage, $page),
                        code => $lang,
+                       html_code => htmllangcode($lang),
+                       html_dir => htmllangdir($lang),
                        language => languagename($lang),
                        percent => percenttranslated($otherpage),
                }
index 3df06e652eeee285d51690b9d2178d6e0fb2b8ca..ccc9cb6664e5617c514ba6715107a2c4d1ddc448 100644 (file)
@@ -41,9 +41,11 @@ sub preprocess (@) {
                        blind_cache => 1);
        };
        if ($@) {
+               # gettext can clobber $@
+               my $error = $@;
                error sprintf(gettext("failed to process template %s"),
                        htmllink($params{page}, $params{destpage},
-                               "/templates/$params{id}"))." $@";
+                               "/templates/$params{id}"))." $error";
        }
 
        $params{basename}=IkiWiki::basename($params{page});
index 41559ea37933166fb9cf26941479ae2cb57cace0..ff2fe8220efa7e68dba25d77df5dbbabcd7b3dc8 100644 (file)
@@ -1,3 +1,31 @@
+ikiwiki (3.20140126) UNRELEASED; urgency=medium
+
+  * Added useragent config setting. Closes: #737121
+    Thanks, Tuomas Jormola
+  * po: Add html_lang_code and html_lang_dir template variables
+    for the language code and direction of text.
+    Thanks, Mesar Hameed
+  * Allow up to 8 levels of nested directives, rather than previous 3
+    in directive infinite loop guard.
+  * git diffurl: Do not escape / in paths to changed files, in order to
+    interoperate with cgit (gitweb works either way)
+    Thanks, intrigeri.
+  * git: Explicity push master branch, as will be needed by git 2.0's
+    change to push.default=matching by default.
+    Thanks, smcv
+  * Deal with nasty issue with gettext clobbering $@ while printing
+    error message containing it.
+    Thanks, smcv
+  * Cleanup of the openid login widget, including replacing of hotlinked
+    images from openid providers with embedded, freely licensed artwork.
+    Thanks, smcv
+  * Improve templates testing.
+    Thanks, smcv
+  * Special thanks to Simon McVittie for being the patchmeister for this
+    release.
+
+ -- Joey Hess <joeyh@debian.org>  Sat, 01 Feb 2014 16:53:35 -0400
+
 ikiwiki (3.20140125) unstable; urgency=medium
 
   * inline: Allow overriding the title of the feed. Closes: #735123
index e1a81932b2f0a5b8145aecbf33f73cb9063f20e5..f3ea9e740d4ad50d46008ea5890360996596f9f8 100644 (file)
@@ -211,6 +211,34 @@ Comment:
  From http://code.google.com/p/openid-selector/
 License: BSD-2-clause
 
+Files: underlays/openid-selector/ikiwiki/openid/goa-*
+Copyright:
+ © 2011 Red Hat, Inc.
+License: LGPL-2.1+
+Comment:
+ taken from data/icons/16x16/ in gnome-online-accounts git
+
+Files: underlays/openid-selector/ikiwiki/openid/wordpress.png
+Copyright:
+ © 2003-2013 "the contributors"
+License: GPL-2+
+Comment:
+ taken from wp-admin/images/w-logo-blue.png in wordpress/3.8.1+dfsg1-1
+ and trivially modified (resized to 16x16, placed on a white background)
+
+Files:
+ icons/aol.svg
+ icons/livejournal.svg
+ icons/verisign.svg
+ underlays/openid-selector/ikiwiki/openid/aol.png
+ underlays/openid-selector/ikiwiki/openid/livejournal.png
+ underlays/openid-selector/ikiwiki/openid/verisign.png
+Copyright:
+ © 2014 Simon McVittie
+License: other
+ Redistribution and use in source and compiled forms, with or without
+ modification, are permitted under any circumstances. No warranty.
+
 Files: underlays/jquery/*
 Copyright: © 2005-2011 by John Resig, Branden Aaron & Jörn Zaefferer
            © 2011 The Dojo Foundation
@@ -301,3 +329,20 @@ License: Expat
  LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
  OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
  SOFTWARE. 
+
+License: LGPL-2.1+
+ This library is free software; you can redistribute it and/or
+ modify it under the terms of the GNU Lesser General Public
+ License as published by the Free Software Foundation; either
+ version 2.1 of the License, or (at your option) any later version.
+ .
+ This library is distributed in the hope that it will be useful,
+ but WITHOUT ANY WARRANTY; without even the implied warranty of
+ MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+ Lesser General Public License for more details.
+ .
+ You should have received a copy of the GNU Lesser General Public License
+ along with this program.  If not, see <http://www.gnu.org/licenses/>.
+ .
+ On Debian systems, the complete text of the GNU Lesser General
+ Public License can be found in `/usr/share/common-licenses/LGPL-2.1'.
index e3b1d858dff019cea76b5f6485904281bdb751dc..15f74c497dfeaf7e9053ee0abf20ff3d7a90ecdc 100644 (file)
@@ -41,3 +41,19 @@ A fix is to change inlinepage.tmpl to remove new lines around tag links, as foll
 > 
 > I don't have the prerequisites for the syntax plugin installed here
 > to debug it myself. --[[Joey]]
+
+> I don't think that this is specific to the [[syntax_(3rd_party)_plugin|plugins/contrib/syntax]].
+> It's happening on my pages that just use ordinary templates.
+> I've documented my versions below. --[[daveloyall]]
+>
+>     ikiwiki: 3.20140125
+>     libtext-markdown-discount-perl: 0.11-1
+>     libtext-multimarkdown-perl: 1.000034-1
+>     libhtml-template-perl: 2.95-1
+
+>> Can you show us the source code and output for a page that has this
+>> bug?
+>>
+>> If you enable [[plugins/htmlbalance]], does the problem go away?
+>> (If it does, then I think I might know what the bug is.)
+>> --[[smcv]]
diff --git a/doc/bugs/assumes___34__git_push_origin__34___is_sufficient.mdwn b/doc/bugs/assumes___34__git_push_origin__34___is_sufficient.mdwn
new file mode 100644 (file)
index 0000000..369be82
--- /dev/null
@@ -0,0 +1,18 @@
+[[!template id=gitbranch branch=smcv/ready/git-push-origin-master
+  browse="http://git.pseudorandom.co.uk/smcv/ikiwiki.git/shortlog/refs/heads/ready/git-push-origin-master"
+  author="[[smcv]]"]]
+[[!tag patch]]
+
+git's behaviour when doing "git push origin" is configurable, and the
+default is going to change in 2.0. In particular, if you've set
+push.default to "nothing" (the "explicit is better than implicit" option),
+the regression test will warn:
+
+    fatal: You didn't specify any refspecs to push, and push.default
+    is "nothing".
+    'git push origin' failed:  at .../lib/IkiWiki/Plugin/git.pm line 220.
+
+The solution is to do "git push origin master" instead (but with the
+configured remote and branch names). --[[smcv]]
+
+> [[fixed|done]] --[[Joey]]
index 1f893b980af6f1b62a6be76cf5809443e98cbe82..b55605245d117afd45d186d12840beda83ea8bfa 100644 (file)
@@ -55,3 +55,20 @@ Weird... --[[anarcat]]
 > > I have a stupid [[patch]] in my git repo which just appends a semicolon to the `::magic()` output, but maybe this should be done in another way...
 > > 
 > > --[[anarcat]]
+
+> > > If the regex match isn't necessary and it's just about deleting the
+> > > parameters, I think I'd prefer something like
+> > >
+> > >     if (! defined $mimetype) {
+> > >         ...
+> > >     }
+> > >     $mimetype =~ s/;.*//;
+> > >
+> > > but I'd be hesitant to do that without knowing why Joey implemented it
+> > > the way it is. If it's about catching a result from file(1) that
+> > > is not, in fact, a MIME type at all (empty string or error message
+> > > or something), maybe something more like this?
+> > >
+> > >     if (! defined $mimetype || $mimetype !~ s{[-\w]+/[-\w]+(?:;.*)?}{})
+> > >
+> > > (or whatever the allowed characters in MIME types are). --[[smcv]]
index bbaa53658f1b534e8b7123ce9d900b6d9f8c38cb..4af8c9f7254a15d76daf0df5eda02fbf4c4a3834 100644 (file)
@@ -65,3 +65,6 @@ error: ikiwiki failed
 > > > Right, I know that. The trick is to find the rabbit hole. :P
 > > > 
 > > > And I found it. With my dev/proxy-utf8-fail, this doesn't fail anymore. Yay, a [[patch]] ready for commit! --[[anarcat]]
+
+> > > > I don't see that branch in your git repo, could you repost it please?
+> > > > (I'm trying to review some of the pending patches.) --[[smcv]]
index 7c7c016cba075dc692aebe6a7c4b9cd169946636..5c1e7b2ed7f6fd60ea72735a940228ec3fcf0f3c 100644 (file)
@@ -30,3 +30,43 @@ A simple fix would be to ship those icons with ikiwiki and serve them locally, b
 > legal stuff involved. (from a practical point of view, things are not that
 > strict, as `apt-file find facebook.png` and `apt-file find flickr.png`
 > reveal.) --[[chrysn]]
+
+>> The fundamental problem here is that we want to balance these
+>> somewhat incompatible goals:
+>>
+>> * show users a provider icon that they'll recognise at a glance
+>> * don't infringe copyright
+>> * don't distribute non-DFSG-licensed things in the source package
+>> * don't let miscellaneous OpenID providers track our users
+>>
+>> A "quick hack" version of removing these would be to have an option to
+>> disable the friendly JavaScript OpenID selector and go back to a simple
+>> input box. I might implement that option anyway - on websites mainly used
+>> by technologists, the OpenID selector is a bit of a waste of time.
+>>
+>>> Not done yet. -s
+>>
+>> One way to have recognisable icons would be to ship DFSG imitations of
+>> the "real" logos in the underlay. Between gnome-online-accounts and
+>> Empathy, we can probably find most of them (mostly or perhaps all done by
+>> Jakub Steiner).
+>>
+>>> [[!template id=gitbranch branch=smcv/ready/openid author="[[smcv]]"]]
+>>> [[!tag patch]]
+>>> Here's a git branch. I deleted the shut-down ClaimID and MyOpenID providers,
+>>> used icons from GNOME Online Accounts and Wordpress where available, and
+>>> drew my own for the rest.
+>>> [See it in use here](http://blueview.hosted.pseudorandom.co.uk/ikiwiki.cgi?do=prefs)
+>>> -s
+>>>>
+>>>> Awesome work Simon! I owe you a beer. [[merged|done]] --[[Joey]] 
+>>
+>> If people want the "real" logos, we could have some code to make IkiWiki
+>> download the favicons into transient underlay (which I think is
+>> higher-priority?), or into a higher-priority underlay if necessary,
+>> during the wiki build, so they'll be served from the wiki's own server.
+>>
+>>> Not done yet. I'm not sure whether I'm going to bother, but I'd review
+>>> someone else's implementation. -s
+>>
+>> --[[smcv]]
diff --git a/doc/bugs/editing_gitbranch_template_is_really_slow.mdwn b/doc/bugs/editing_gitbranch_template_is_really_slow.mdwn
new file mode 100644 (file)
index 0000000..d8af150
--- /dev/null
@@ -0,0 +1,31 @@
+On this wiki, editing `templates/gitbranch.mdwn` causes a really slow
+refresh, orders of magnitude slower than a full rebuild: a large number of
+pages depend on that template, or link to a page that embeds that template,
+and so on.
+
+I suspect that, as with my optimization pass for `album`'s benefit, the
+costly thing is evaluating lots of pagespecs. I'm profiling it to see
+whether the problem is there are any low-hanging fruit.
+
+Easy to reproduce offline:
+
+* comment out the `exclude` option in `docwiki.setup`
+* `/usr/bin/perl -Iblib/lib ikiwiki.in -setup docwiki.setup -rebuild`
+* `touch templates/gitbranch.mdwn`
+* `/usr/bin/perl -Iblib/lib ikiwiki.in -setup docwiki.setup -refresh`
+
+NYTProf says:
+
+    # spent 279s (237+41.8) within IkiWiki::bestlink which was called 13988949 times, avg 20µs/call:
+    # 13150827 times (222s+37.2s) by IkiWiki::PageSpec::match_link at line 2692, avg 20µs/call
+    # 829606 times (14.9s+4.51s) by IkiWiki::PageSpec::match_link at line 2687, avg 23µs/call
+    ...
+    sub bestlink ($$) {
+
+which is about half the execution time (458s on my laptop).
+
+Adding code to log each call to match_backlink indicates that a large part
+of the problem is that it evaluates the pagespec
+`backlink(plugins/goodstuff)` up to a million times, with various pages and locations.
+
+--[[smcv]]
diff --git a/doc/bugs/error_handlers_with_gettext_can_clobber___36____64__.mdwn b/doc/bugs/error_handlers_with_gettext_can_clobber___36____64__.mdwn
new file mode 100644 (file)
index 0000000..00656c1
--- /dev/null
@@ -0,0 +1,27 @@
+[[!template id=gitbranch branch=smcv/ready/careful-eval author="[[smcv]]"
+  browse="http://git.pseudorandom.co.uk/smcv/ikiwiki.git/shortlog/refs/heads/ready/careful-eval"]]
+[[!tag patch]]
+
+As noted in the [[!cpan Try::Tiny]] man page, eval/$@ can be quite
+awkward in corner cases, because $@ has the same properties and problems
+as C's errno. While writing a regression test for definetemplate
+in which it couldn't find an appropriate template, I received
+    
+    <span class="error">Error: failed to process template
+    <span class="createlink">deftmpl</span> </span>
+    
+instead of the intended
+    
+    <span class="error">Error: failed to process template
+    <span class="createlink">deftmpl</span> template deftmpl not
+    found</span>
+    
+which turned out to be because the "catch"-analogous block called
+gettext before it used $@, and gettext can call define_gettext,
+which uses eval.
+
+Fixed in my branch smcv/ready/careful-eval. Another possibility
+for fixing this would be to depend on something like Try::Tiny,
+which is already indirectly recommended by ikiwiki, because
+[[!cpan RPC::XML]], [[!cpan XML::Feed]], etc., depend on it.
+--[[smcv]]
index 87588cb089de5d8a1c365179d7d307058139a326..b462948ebc3d0f65ad2ccd21be08f7e03e8cb622 100644 (file)
@@ -34,4 +34,63 @@ The [[ikiwiki/directive/listdirectives]]` directive doesn't register a link betw
 > --[[smcv]]
 
 > No follow-up or objection for a while, so considering this to
-> be [[working as designed|done]]. --[[smcv]]
+> be working as designed. --[[smcv]]
+
+> > Seems I'm a bit late to butt in, but would it be possible to have two
+> > further phases after the scan phase, the first running map and inline 
+> > and the second orphan? Then map and inline could log or register their 
+> > links (obviously somewhere were it won't change the result of the link function)
+> > and orphan could take them into account. This logging could be
+> > turned on by parameter to not waste time for users not needing this and 
+> > make it tunable (i.e. so that the user can decide which map directives count and which don't)
+> > 
+> > For someone using map and especially autoindex the output of the orphans directive
+> > is simply wrong/useless (at least it is for me). And there is no easy workaround like for listdirectives
+> > -- [[holger]]
+
+>>> Hmm. I think this can be done without introducing any "phases",
+>>> even, but it would require each plugin that generates links according
+>>> to a pagespec to have either a conditional call into the orphans plugin,
+>>> or a call to a new core function in ikiwiki that exists solely to
+>>> support the orphans plugin. Something like this, maybe:
+>>>
+>>>     # in map.pm, inline.pm, pagestats.pm etc., at scan time
+>>>     if (IkiWiki::Plugin::orphans->can("add_reachable")) {
+>>>         IkiWiki::Plugin::orphans::add_reachable($page, $pagespec);
+>>>     }
+>>>
+>>>     # in orphans.pm (pseudocode; note that this does not *evaluate*
+>>>     # $pagespec, only stores it, so it's OK to do this at scan time)
+>>>     sub needsbuild ($pages)
+>>>         for each page in $pages
+>>>             clear $pagestate{location}{orphans}{reachable}
+>>>     sub reachable ($location, $pagespec)
+>>>         add $pagespec to @{$pagestate{location}{orphans}{reachable}}
+>>>
+>>>     # in preprocess function in orphans.pm (pseudocode)
+>>>     # executed at build time, not at scan time, so pagespecs work
+>>>
+>>>     for each maybe_orphan with no links to it
+>>>         for each location with a list of reachable pagespecs
+>>>             make the page with the orphans directive depend on \
+>>>                 the page that is the location
+>>>             for each of those pagespecs
+>>>                 if pagespec matches orphan
+>>>                     take orphan off the list
+>>>                     go to next orphan
+>>>     output list of orphans
+>>>
+>>> (Maybe parentlinks should also annotate the parent/ancestors of
+>>> each page as reachable from that page.)
+>>>
+>>> Do other people (mainly Joey) think that'd be acceptable, or
+>>> too intrusive?
+>>>
+>>> Taking this off the list of resolved bugs again while we think about it.
+>>>
+>>> I suspect that in the presence of autoindex, what you really want might
+>>> be less "there's a link to it" and more "there's a path to it from
+>>> the root of the wiki", which is why I called the proposed function
+>>> "add_reachable". On the other hand, maybe that's too computationally
+>>> intensive to actually do; I haven't tried it.
+>>> --[[smcv]]
index f7e115d48feb5d7cecc5204e2dbd1a744b9a8f7e..c031543c111d5ee0ec9c662379d50eef9eb57164 100644 (file)
@@ -14,3 +14,6 @@ Maybe just encode all &lt; and &gt; when compling pages within the templates fol
 
 > I never noticed this bug, since it only happens if the htmlscrubber is
 > disabled. --[[Joey]]
+
+>> My `templatebody` branch on [[template creation error]] fixes this.
+>> --[[smcv]]
index f1a9bc9a7c7eaf9eae3ac94003b38f546598e1da..807d6b7ef4e50e13a75a4d144e99afd48823e78e 100644 (file)
@@ -17,3 +17,7 @@ index 75c9579..ad0f8b0 100644
 </pre></code>
 
 [[!tag patch]]
+
+> [[Seems reasonable|users/smcv/yesplease]] --smcv
+
+>> [[done]] --[[Joey]]
index dad974a81bd51d87f596a21e94833d3eac446d17..b641f2db29babbb973be79b3a6cabcad99c6e9a5 100644 (file)
@@ -21,3 +21,7 @@ Yet I am not sure how to fix that kind of problem in Perl... --[[anarcat]]
 > I have improved a little the error handling in log_message() so that we see *something* when syslog fails, see the branch documented above. I can also confirm that  reverting [[todo/syslog_should_show_wiki_name]] fixes the bug. Finally, I have a unit test that reproduces the problem in git, and a working [[!taglink patch]] for the bug, again in git.
 > 
 > > One last note: I noticed that this problem also happens elsewhere in ikiwiki. For example, the [[plugins/notifyemail]] plugin will silently fail to send notifications if the pages contain unicode. The [[plugins/notifychanges]] plugin I am working on (in [[todo/option to send only the diff in notifyemail]]) seems to be working around the issue so far, but there's no telling which similar problem are out there.
+
+>> [[I'd merge it|/users/smcv/yesplease]]. --[[smcv]]
+
+>>> I've merged it, but I don't feel it fixes this bug. --[[Joey]]
diff --git a/doc/bugs/template__95__syntax_test_is_incomplete.mdwn b/doc/bugs/template__95__syntax_test_is_incomplete.mdwn
new file mode 100644 (file)
index 0000000..d50b727
--- /dev/null
@@ -0,0 +1,10 @@
+[[!template id=gitbranch branch=smcv/ready/template-syntax-test
+  browse="http://git.pseudorandom.co.uk/smcv/ikiwiki.git/shortlog/refs/heads/ready/template-syntax-test"
+  author="[[smcv]]"]]
+[[!tag patch]]
+
+`t/template_syntax.t` looks as though it's meant to check the syntax of
+`doc/templates/*.mdwn` as well as `templates/*.tmpl`, but it doesn't.
+Patch in my git repository. --[[smcv]]
+
+> [[merged|done]] --[[Joey]]
index 5d27c347232b69bf65758f31b9a49df27575e225..f14652ed8284bdefa94d09ba029e29e47a9e235d 100644 (file)
@@ -110,8 +110,6 @@ Please, let me know what to do to avoid this kind of error.
 >
 > --[[smcv]]
 
->> [[!template id=gitbranch author="[[smcv]]" branch=smcv/definetemplate]]
->> [[!tag patch]]
 >> OK, here is a branch implementing what I said. It adds the `definetemplate`
 >> directive to [[plugins/goodstuff]] as its last commit.
 >>
@@ -195,3 +193,28 @@ Please, let me know what to do to avoid this kind of error.
 >>>>> the right thing to do in this situation.
 >>>>>
 >>>>> --[[chrysn]]
+
+>>>>>> [[!template id=gitbranch author="[[smcv]]" branch=smcv/ready/templatebody
+         browse=http://git.pseudorandom.co.uk/smcv/ikiwiki.git/shortlog/refs/heads/ready/templatebody]]
+>>>>>> [[!tag patch]]
+>>>>>> Branch and directive renamed to `ready/templatebody` as chrysn suggested.
+>>>>>> It's on-by-default now (or will be if that branch is merged).
+>>>>>> Joey, any chance you could review this?
+>>>>>>
+>>>>>> There is one known buglet: `template_syntax.t` asserts that the entire
+>>>>>> file is a valid HTML::Template, whereas it would ideally be doing the
+>>>>>> same logic as IkiWiki itself. I don't think that's serious. --[[smcv]]
+
+>>>>>>> Looking over this, I notice it adds a hash containing all scanned
+>>>>>>> files. This seems to me to be potentially a scalability problem on
+>>>>>>> rebuild of a site with many pages. Ikiwiki already keeps a lot
+>>>>>>> of info in memory, and this adds to it, for what is a fairly
+>>>>>>> minor reason. It seems to me there should be a way to avoid this. --[[Joey]] 
+
+>>>>>>>> Maybe. Are plugins expected to cope with scanning the same
+>>>>>>>> page more than once? If so, it's just a tradeoff between
+>>>>>>>> "spend more time scanning the template repeatedly" and
+>>>>>>>> "spend more memory on avoiding it", and it would be OK to
+>>>>>>>> omit that, or reduce it to a set of scanned *templates*
+>>>>>>>> (in practice that would mean scanning each template twice
+>>>>>>>> in a rebuild). --s
diff --git a/doc/forum/How_can_I_invert_the_banned__95__user_check__63__.mdwn b/doc/forum/How_can_I_invert_the_banned__95__user_check__63__.mdwn
new file mode 100644 (file)
index 0000000..2436b2e
--- /dev/null
@@ -0,0 +1,33 @@
+Trying to lockdown a wiki so that it can only be edited by certain users and figured I'd just set
+
+     banned_users:
+     - !user(myadmin)
+
+in my config but it doesn't work.  I'm sure I must be doing something daft?
+
+PS: the user is authenticated via 'httpauth', would that make a difference?
+
+> That's not how `banned_users` works. Make yourself an admin:
+>
+>     adminuser:
+>     - myadmin
+>
+> and disallow editing by non-admins:
+>
+>     locked_pages: '*'
+>
+> You can enable the `opendiscussion` and/or `anonok` plugins if you want
+> unprivileged users, perhaps logging in with an OpenID, to be able to
+> edit discussion pages (if enabled via `discussion`) or post comments.
+>
+> You can also relax the `locked_pages` setting if you want unprivileged
+> users to be able to edit certain areas of the site.
+>
+> --[[smcv]]
+
+>> That was my initial setup but it wasn't working and I got caught-up on the `banned_user` idea.  It would seem I was getting tricked by some credential-caching-weirdness.  Fired up another browser and `locked_pages` works perfectly.  Thanks.  -- fergus
+
+>>> Browsers generally remember HTTP auth credentials until they're closed
+>>> or get a 401 error, and don't generally have a way to "log out".
+>>> As far as I'm aware, there's nothing that [[plugins/httpauth]] can
+>>> do about that. --[[smcv]]
index 2b56bd70b27de13e12432636a18c38e15698ab2e..e01eccb92c4f6c98cb5b4687f3978a2cf4760ee1 100644 (file)
@@ -1,4 +1,4 @@
-as in title, how to align text to the right?
+As in title, how to align text to the right?
 
 > Add to your local.css a class that aligns text to the right:
 
@@ -13,3 +13,40 @@ as in title, how to align text to the right?
 > [[templates/note]] template does something similar. --[[Joey]]
 
 >> Thanks!
+
+-----
+<div class="notebox">
+[[!format mdwn """
+This is my text with [a markdown link](#).
+
+Here's a *second* paragraph.
+"""]]
+</div>
+
+> There is more than one way to do it. If [[plugins/format]] is enabled, then this:
+>
+>     <div class="notebox">
+>     \[[!format mdwn """
+>     This is my text with [a markdown link](#).
+>
+>     Here's a *second* paragraph.
+>     """]]
+>     </div>
+>
+> is rendered like the box in this page.
+>
+> (I'm using the `notebox` class used by the `note` template here, but you could
+> use any class.) --[[smcv]]
+
+-----
+> Doing this myself and noted that [[ikiwiki/markdown]] down does not allow the enclosure of block level elements directly; and thus we cannot switch the `span` suggested above for `div` in changing block level elements (not if you wish to include markdown, anyway).  For example, I want to create a paragraph (with markdown text) which is right aligned, and so add the following
+
+>>     <span class="right_align">
+>>     This is my text with [a markdown link](/)
+>>     </span>
+
+> The *correct* thing to do here is create a template (as indicated above) **but** a workaround I found useful was to over-ride the `inline` nature of the `span` element, as follows
+
+>>     .align_right { display: block ; text-align: right ; }
+
+> you may also like to remove the padding and margins since they will be provided by the enclosing block. -- fergus
index 569c2818f01835fcbacb24e5d873059c990a8ed4..a6f301dd3c5906548fcdfd3853dd33937abe96d7 100644 (file)
@@ -2,7 +2,7 @@ The `edittemplate` directive is supplied by the [[!iki plugins/edittemplate desc
 
 This directive allows registering template pages, that provide default
 content for new pages created using the web frontend. To register a
-template, insert a [[ikiwiki/directive/template]] directive on some other
+template, insert an [[ikiwiki/directive/edittemplate]] directive on some other
 page.
 
        \[[!edittemplate template="bugtemplate" match="bugs/*"]]
diff --git a/doc/ikiwiki/directive/edittemplate/discussion.mdwn b/doc/ikiwiki/directive/edittemplate/discussion.mdwn
new file mode 100644 (file)
index 0000000..81db204
--- /dev/null
@@ -0,0 +1,2 @@
+For some years now I do feel quite comfortable when using all things *template. But one thing I stumble across when setting up another ikiwiki driven site is a sort of misleading resp. missing description with the [[edittemplate]] directive, where it says "(Don't put the directive on the template page itself)". While this is right there should also be mentioned that "the page holding the edittemplage directive must not be named the same as the template page it refers to". At least with my usual setup the edittemplate directive will not work whenever I attempt to simplify things by giving it the same name as the template page.   
+Boris
index 70d5042b774e5f2ad1eb0f13c81706a4af1e4704..ea0e98d438cdc27dcde73a15c3d21a7b667f89a9 100644 (file)
@@ -50,7 +50,6 @@ Projects & Organizations
 * [Public Domain collection of Debian related tips & tricks](http://dabase.com/tips/) - please add any tips too
 * [Finnish Debian community](http://debian.fi)
 * [dist-bugs](http://dist-bugs.kitenet.net/)
-* [Chaos Computer Club Düsseldorf](https://www.chaosdorf.de)
 * [monkeysphere](http://web.monkeysphere.info/)
 * [Cosin Homepage](http://cosin.ch) uses an Ikiwiki with a subversion repository.
 * [Bosco Free Orienteering Software](http://bosco.durcheinandertal.ch)
@@ -89,6 +88,7 @@ Projects & Organizations
 * [[Nos oignons|http://nos-oignons.net]] - Tor exit nodes funded by the community.
 * [[CAS Libres|http://cas-libres.poivron.org]] - A French feminist radio program.
 * [[Les Barricades|http://barricades.int.eu.org]] - A French socialist choir (CSS has been adapted from the one of [[Grésille|http://www.gresille.org]]).
+* [DKØTU Amateur Radio Station](http://www.dk0tu.de), TU Berlin
 
 Personal sites and blogs
 ========================
diff --git a/doc/news/version_3.20130710.mdwn b/doc/news/version_3.20130710.mdwn
deleted file mode 100644 (file)
index f1b30a7..0000000
+++ /dev/null
@@ -1,23 +0,0 @@
-ikiwiki 3.20130710 released with [[!toggle text="these changes"]]
-[[!toggleable text="""
-   * blogspam: Fix encoding issue in RPC::XML call.
-     Thanks, Changaco
-   * comments: The formats allowed to be used in comments can be configured
-     using comments\_allowformats.
-     Thanks, Michal Sojka
-   * calendar: When there are multiple pages for a given day, they're
-     displayed in a popup on mouseover.
-     Thanks, Louis
-   * osm: Remove trailing slash from KML maps icon.
-   * page.tmpl: omit searchform, trails, sidebar and most metadata in CGI
-     (smcv)
-   * openid: Automatically upgrade openid\_realm to https when
-     accessed via https.
-   * The ip() pagespec can now contain glob characters to match eg, a subnet
-     full of spammers.
-   * Fix crash that could occur when a needsbuild hook returned a file
-     that does not exist.
-   * Fix python proxy to not crash when fed unicode data in getstate
-     and setstate.
-     Thanks, chrysn
-   * Fix committing attachments when using svn."""]]
\ No newline at end of file
diff --git a/doc/news/version_3.20140125.mdwn b/doc/news/version_3.20140125.mdwn
new file mode 100644 (file)
index 0000000..3ef6ab3
--- /dev/null
@@ -0,0 +1,5 @@
+ikiwiki 3.20140125 released with [[!toggle text="these changes"]]
+[[!toggleable text="""
+   * inline: Allow overriding the title of the feed. Closes: #[735123](http://bugs.debian.org/735123)
+     Thanks, Christophe Rhodes
+   * osm: Escape name parameter. Closes: #[731797](http://bugs.debian.org/731797)"""]]
\ No newline at end of file
diff --git a/doc/plugins/contrib/nimble.mdwn b/doc/plugins/contrib/nimble.mdwn
new file mode 100644 (file)
index 0000000..29e2686
--- /dev/null
@@ -0,0 +1,6 @@
+[[!template id=plugin name=nimble author="[[schmonz]]"]]
+[[!template id=gitbranch branch=schmonz/nimble author="[[schmonz]]"]]
+[[!tag type/format]]
+
+This plugin lets ikiwiki convert [Nimble](http://was.tl/projects/nimble/)
+to HTML.
index ff8b986ec16ff062af7372339481f92b53f63ac3..06c2d7ca72e01c8f48e81e29a29a02aaff597c78 100644 (file)
@@ -95,3 +95,24 @@ This is an email link:
 <a href="mailto:erik.josefsson@europarl.europa.eu?Subject=Hello%20again" target="_top">
 Send Mail</a>
 </p>
+
+This is some preformatted text.  Each line is proceeded by four spaces.
+
+    Test
+
+    <Test>
+
+    <test>
+    <test>
+
+    <test>
+      <child />
+    </test>
+
+...Now why doesn't it work like that on my copy of ikiwiki? :(
+
+Räksmörgås.
+
+`pre?`
+
+
diff --git a/doc/sandbox/New_blog_entry.mdwn b/doc/sandbox/New_blog_entry.mdwn
new file mode 100644 (file)
index 0000000..9327285
--- /dev/null
@@ -0,0 +1,3 @@
+Räksmörgåstest.
+
+ハッカー
index 4fdf937ff2da6be6b794cb44dce850f08700b548..853da92801ffc8c039c29f9133238cd4342aa4d6 100644 (file)
@@ -1,8 +1,8 @@
-<span class="infobox">
+<div class="infobox">
 Available in a [[!taglink /git]] repository [[!taglink branch|/branches]].<br />
-Branch: <TMPL_VAR branch><br />
-Author: <TMPL_VAR author><br />
-</span>
+Branch: <TMPL_IF browse><a href="<TMPL_VAR browse>"></TMPL_IF><TMPL_VAR branch><TMPL_IF browse></a></TMPL_IF><br />
+<TMPL_IF author>Author: <TMPL_VAR author><br /></TMPL_IF>
+</div>
 <TMPL_UNLESS branch>
 This template is used to create an infobox for a git branch. It uses
 these parameters:
index baf7ac6c8272447a3084d9bede6dea072a7dc737..35feacb714f6d7d3355bb06eb3c2c519b653ec99 100644 (file)
@@ -149,3 +149,8 @@ the IkiWiki machine, and here is the deadlock. Explanations of the command:
 - *Using [[gitolite|https://github.com/sitaramc/gitolite]] to manage
   repositories on the git machine* Simply replace the manipulations of git on
   the git machine by the corresponding manipulations using gitolite.
+    * With gitolite, you can use this line in a `post-update` hook:
+
+        `[ x"$GL_USER" = x"`*`gitolite-user`*`" ] || wget ...`
+
+        thus, you filter out precisely the events that originate from the server-to-be-pinged, no matter what the commit id says. (For example, if you push commits you created on a local CGI ikiwiki, they'd be called '@web' as well).
index 16fc3c5121cb6821e8568757db126d45976a1cac..8bbb7c2cf912bbb7cd26d0dc0ed9eef747fbbe72 100644 (file)
@@ -182,3 +182,15 @@ Here is a [[patch]] that adds an option `disp` for the [[ikiwiki/directive/pages
 
 Regards,  
 -- [[Louis|spalax]]
+
+> Saved to my git repository as `contrib/spalax/pagestats-disp`.
+> I'd rather find a better name than `disp` for the parameter.
+> I think `display` would be an improvement, but that doesn't solve the
+> problem of "it's a synonym for show, and non-obvious which is which".
+> Maybe `linktext`?
+> 
+> It's unfortunate that `map` and `pagestats` have different meanings for
+> the `show` parameter. I'm tempted to propose a patch that adds something
+> like `limit` (by analogy with SQL) or `max` as the canonical name for the
+> "number of things to match" parameter, at which point a non-numeric
+> `show` could mean this thing. --[[smcv]]
diff --git a/doc/todo/bitcoin_URI_scheme.mdwn b/doc/todo/bitcoin_URI_scheme.mdwn
new file mode 100644 (file)
index 0000000..a0f3e11
--- /dev/null
@@ -0,0 +1,16 @@
+This is a tiny feature request:
+
+add the bitcoin URI scheme [1] to ikiwiki.
+
+This can be done by adding '"bitcoin",' to Ikiwiki/Plugin/htmlscrubber.pm
+
+-              "aim", "callto", "cvs", "ed2k", "feed", "fish", "gg",
+to
++              "aim", "bitcoin", "callto", "cvs", "ed2k", "feed", "fish", "gg",
+
+thanks
+
+flowolf
+[1]: http://en.wikipedia.org/wiki/URI_scheme
+
+> I agree and this was important enough to fire up the ol' wayback machine, set the dial to one year ago today, and fix it then, in version 3.20130212. [[done]]. As a bonus, in this new hardforked casuality chain, someone sent me half a bitcoin using this feature. --[[Joey]]
index 7ec95b536d45ea659b21aaa29332a918033fa11e..4f83c8bf555139f7f9d6c27f32e70ba93b401e18 100644 (file)
@@ -1,3 +1,4 @@
+[[!template id=gitbranch branch=anderbubble/edittemplate author="Jonathon Anderson"]]
 [[!tag wishlist patch]]
 
 I use a default template for all new pages:
@@ -17,3 +18,31 @@ I've already made these changes in my installation, and have made my patches ava
 Changes to the structure of `$pagestate{$registering_page}{edittemplate}{$pagespec}` mean that a `cgi` rebuild is necessary (for reasons I don't entirely understand); but I think that's preferable to creating an entirely separate `$pagestate` namespace for storing parameters.  That said, I'm not really a perl programmer, so corrections are welcome.
 
 > I like this patch. I hate seeing things I've already read get marked as unread in my rss feed. -- [[JoshBBall]]
+
+>> (I don't have commit access so take this with a pinch of salt -
+>> I'm just trying to help deal with the code-review backlog.)
+>>
+>> I mostly like the first and third patches in the branch (adding v4
+>> (random) UUIDs, and adding the timestamps). I'd be tempted to rename
+>> `time` and `formatted_time` to `iso_time` and `time`, but that's
+>> a matter of taste, and perhaps people with commit access have
+>> stronger opinions one way or another. I haven't researched
+>> whether there's precendent for any particular naming style
+>> elsewhere in ikiwiki.
+>>
+>> The UUID bit would require adding some reference to libuuid-tiny-perl
+>> to the Debian packaging - I think a `Recommends` is too strong
+>> but a `Suggests` seems OK.
+>>
+>> I don't like the second patch (adding URL-namespaced UUID support).
+>> I'm having a hard time thinking of any situation in which a v4 UUID
+>> would be unsuitable, which means it's unnecessary complexity.
+>> FYI, the reason that it makes a rebuild is necessary is that
+>> you've restructured `$pagestate`, which is carried over from one
+>> refresh to the next (that's its purpose), and you haven't
+>> built in any migration or backwards-compatibility code that will
+>> cope with it being in the old format. My inclination would be to
+>> drop that patch. If there's a really good reason to prefer
+>> v3/v5 UUIDs, please describe it and I'll try to suggest some
+>> better way based on that, maybe global configuration in `$config`.
+>> --[[smcv]]
index c68834456d565b2b1d52409cc3c1773584c3ae49..f321e4f5299bddab3e2649bb84246326710c068f 100644 (file)
@@ -8,3 +8,8 @@ This means:
 2. Content can correctly be tagged with the language code, to enable screenreaders and other accessibility providers to render/speak the text in the correct language.
 
 The [[patch]] is currently being used on http://addons.nvda-project.org and seems to work well. --[[mhameed]]
+
+> I don't have commit access, but it [[seems reasonable|/users/smcv/yesplease]].
+> --[[smcv]]
+
+>> [[done]]] --[[Joey]]
index cecac7a94010dec37e9caf6b4eec4c414c426d4a..b257760cef4b6f8b1bdf307fe05553efe8d2310a 100644 (file)
@@ -30,6 +30,12 @@ This patch, or one like it, would enable better blogging support, by adding
 the ability to hierarchically organize blog posts and automatically generate
 structural pages for year, month, or day. Please apply. --Ethan
 
+> This looks a lot like [[plugins/autoindex]], except limited to a subset
+> of pages, and with different templates according to the page it's used
+> on. Perhaps it could become several enhancements for autoindex? --[[smcv]]
+
+----
+
 <pre>
 Index: IkiWiki/Render.pm
 ===================================================================
index 00afb82fd6ea31a79d27fc023763a7d4b56ef897..ab6172ad1dc8a40fd95c56e718f57ab75376ade3 100644 (file)
@@ -25,6 +25,21 @@ the substitution of `\[[file]]` in `diffurl` and `historyurl`?
 >>> for the Git plugin. Please review and merge if you like
 >>> it. --[[intrigeri]]
 
+>>>> Ping? --[[intrigeri]]
+
+>>>> Normally, my tendency towards pedantic preservation of existing APIs
+>>>> would make me implement a new token \[[file_less_escaped]] or
+>>>> something, analogous to `%s` vs. `%S` in [[shortcuts]]; but
+>>>> gitweb and cgit are both OK with `/` not being escaped, whereas
+>>>> only gitweb allows it to be escaped as `%2F`, so I think your
+>>>> solution is fine. Also, it would need a much better name than
+>>>> \[[file_less_escaped]], and I can't think of one.
+>>>>
+>>>> I don't have commit access to ikiwiki.info, but if I did,
+>>>> [[I'd merge this|/users/smcv/yesplease]]. --[[smcv]]
+
+>>>>> [[merged|done]] --[[Joey]]
+
 [[wishlist]]
 
 [[!tag patch]]
diff --git a/doc/users/holger.mdwn b/doc/users/holger.mdwn
new file mode 100644 (file)
index 0000000..9f0e3c0
--- /dev/null
@@ -0,0 +1,3 @@
+I'm sysadmin at a german university. 
+
+I'm using ikiwiki as personal wiki at work and at home.
index 59d1affba20f97c4e8e7f7db94588cb9a5533076..a4eb564cefd9108174b258b7db31a05e3997ba28 100644 (file)
@@ -7,4 +7,4 @@ My repository containing ikiwiki branches:
 * gitweb: http://git.pseudorandom.co.uk/smcv/ikiwiki.git
 * anongit: git://git.pseudorandom.co.uk/git/smcv/ikiwiki.git
 
-Currently thinking about a [[users/smcv/gallery]] plugin.
+Recently tried to [[help with the review backlog|yesplease]].
diff --git a/doc/users/smcv/yesplease.mdwn b/doc/users/smcv/yesplease.mdwn
new file mode 100644 (file)
index 0000000..b100b37
--- /dev/null
@@ -0,0 +1,7 @@
+A tag for patches that I would merge if I had commit access to ikiwiki,
+in the hope that it's a useful shortlist for committers to look at.
+They're mirrored in my git repository under the `ready/*` namespace.
+
+[[!inline pages="(todo/* or bugs/*) and link(patch) and !link(bugs/done) and
+   !link(todo/done) and link(users/smcv/yesplease) and !*/Discussion"
+   archive="yes"]]
diff --git a/icons/aol.svg b/icons/aol.svg
new file mode 100644 (file)
index 0000000..3986767
--- /dev/null
@@ -0,0 +1,101 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+   xmlns:dc="http://purl.org/dc/elements/1.1/"
+   xmlns:cc="http://creativecommons.org/ns#"
+   xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+   xmlns:svg="http://www.w3.org/2000/svg"
+   xmlns="http://www.w3.org/2000/svg"
+   xmlns:xlink="http://www.w3.org/1999/xlink"
+   xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
+   xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
+   width="16px"
+   height="16px"
+   id="svg2985"
+   version="1.1"
+   inkscape:version="0.48.4 r9939"
+   sodipodi:docname="aol.svg"
+   inkscape:export-filename="/home/smcv/src/ikiwiki/icons/aol.png"
+   inkscape:export-xdpi="90"
+   inkscape:export-ydpi="90">
+  <title
+     id="title3812">approximately the AOL logo</title>
+  <defs
+     id="defs2987">
+    <linearGradient
+       inkscape:collect="always"
+       id="linearGradient3781">
+      <stop
+         style="stop-color:#000000;stop-opacity:1;"
+         offset="0"
+         id="stop3783" />
+      <stop
+         style="stop-color:#000000;stop-opacity:0;"
+         offset="1"
+         id="stop3785" />
+    </linearGradient>
+    <linearGradient
+       inkscape:collect="always"
+       xlink:href="#linearGradient3781"
+       id="linearGradient3787" />
+  </defs>
+  <sodipodi:namedview
+     id="base"
+     pagecolor="#ffffff"
+     bordercolor="#666666"
+     borderopacity="1.0"
+     inkscape:pageopacity="0.0"
+     inkscape:pageshadow="2"
+     inkscape:zoom="1"
+     inkscape:cx="19.271071"
+     inkscape:cy="3.271264"
+     inkscape:current-layer="layer1"
+     showgrid="true"
+     inkscape:grid-bbox="true"
+     inkscape:document-units="px"
+     inkscape:window-width="1366"
+     inkscape:window-height="717"
+     inkscape:window-x="0"
+     inkscape:window-y="27"
+     inkscape:window-maximized="1" />
+  <metadata
+     id="metadata2990">
+    <rdf:RDF>
+      <cc:Work
+         rdf:about="">
+        <dc:format>image/svg+xml</dc:format>
+        <dc:type
+           rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
+        <dc:title>approximately the AOL logo</dc:title>
+        <dc:creator>
+          <cc:Agent>
+            <dc:title>Simon McVittie</dc:title>
+          </cc:Agent>
+        </dc:creator>
+        <dc:date>2014</dc:date>
+        <dc:rights>
+          <cc:Agent>
+            <dc:title>ikiwiki basewiki license</dc:title>
+          </cc:Agent>
+        </dc:rights>
+      </cc:Work>
+    </rdf:RDF>
+  </metadata>
+  <g
+     id="layer1"
+     inkscape:label="Layer 1"
+     inkscape:groupmode="layer">
+    <text
+       xml:space="preserve"
+       style="font-size:8.92135143px;font-style:normal;font-variant:normal;font-weight:bold;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Liberation Sans;-inkscape-font-specification:Liberation Sans Bold"
+       x="-0.16655508"
+       y="11.176648"
+       id="text3841"
+       sodipodi:linespacing="125%"><tspan
+         sodipodi:role="line"
+         id="tspan3843"
+         x="-0.16655508"
+         y="11.176648">Aol.</tspan></text>
+  </g>
+</svg>
diff --git a/icons/livejournal.svg b/icons/livejournal.svg
new file mode 100644 (file)
index 0000000..381d881
--- /dev/null
@@ -0,0 +1,108 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+   xmlns:dc="http://purl.org/dc/elements/1.1/"
+   xmlns:cc="http://creativecommons.org/ns#"
+   xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+   xmlns:svg="http://www.w3.org/2000/svg"
+   xmlns="http://www.w3.org/2000/svg"
+   xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
+   xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
+   width="16px"
+   height="16px"
+   id="svg2985"
+   version="1.1"
+   inkscape:version="0.48.4 r9939"
+   sodipodi:docname="New document 2">
+  <title
+     id="title3825">A pencil resembling the Livejournal logo</title>
+  <defs
+     id="defs2987" />
+  <sodipodi:namedview
+     id="base"
+     pagecolor="#ffffff"
+     bordercolor="#666666"
+     borderopacity="1.0"
+     inkscape:pageopacity="0.0"
+     inkscape:pageshadow="2"
+     inkscape:zoom="1"
+     inkscape:cx="-26.375015"
+     inkscape:cy="3.6372964"
+     inkscape:current-layer="layer1"
+     showgrid="true"
+     inkscape:grid-bbox="true"
+     inkscape:document-units="px"
+     showguides="true"
+     inkscape:guide-bbox="true"
+     inkscape:window-width="1366"
+     inkscape:window-height="717"
+     inkscape:window-x="0"
+     inkscape:window-y="27"
+     inkscape:window-maximized="1" />
+  <metadata
+     id="metadata2990">
+    <rdf:RDF>
+      <cc:Work
+         rdf:about="">
+        <dc:format>image/svg+xml</dc:format>
+        <dc:type
+           rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
+        <dc:title>A pencil resembling the Livejournal logo</dc:title>
+        <dc:creator>
+          <cc:Agent>
+            <dc:title>Simon McVittie</dc:title>
+          </cc:Agent>
+        </dc:creator>
+        <dc:rights>
+          <cc:Agent>
+            <dc:title>ikiwiki basewiki license</dc:title>
+          </cc:Agent>
+        </dc:rights>
+        <dc:date>2014</dc:date>
+      </cc:Work>
+    </rdf:RDF>
+  </metadata>
+  <g
+     id="layer1"
+     inkscape:label="Layer 1"
+     inkscape:groupmode="layer">
+    <rect
+       style="color:#000000;fill:#729fcf;fill-opacity:1;fill-rule:nonzero;stroke:#2e3436;stroke-width:0.5;marker:none;visibility:visible;display:inline;overflow:visible;enable-background:accumulate;stroke-miterlimit:4;stroke-dasharray:none"
+       id="rect3015"
+       width="16.103926"
+       height="3.75"
+       x="-3.1922383"
+       y="-4.2015886"
+       transform="matrix(0.68662998,0.72700707,-0.72700707,0.68662997,0,0)" />
+    <rect
+       style="color:#000000;fill:#3465a4;fill-opacity:1;fill-rule:nonzero;stroke:#2e3436;stroke-width:0.5;marker:none;visibility:visible;display:inline;overflow:visible;enable-background:accumulate;stroke-miterlimit:4;stroke-dasharray:none"
+       id="rect3017"
+       width="16.103926"
+       height="3.5"
+       x="-3.1922383"
+       y="-0.45158866"
+       transform="matrix(0.68662998,0.72700707,-0.72700707,0.68662997,0,0)" />
+    <path
+       style="color:#000000;fill:#e9b96e;fill-opacity:1;fill-rule:nonzero;stroke:#2e3436;stroke-width:0.50000000000000000;marker:none;visibility:visible;display:inline;overflow:visible;enable-background:accumulate;stroke-miterlimit:4;stroke-dasharray:none;stroke-linejoin:bevel"
+       d="M 11.90625 6.53125 L 11.8125 6.59375 L 10.125 7.28125 L 8.34375 7.96875 L 7.53125 9.75 L 6.8125 11.28125 L 6.65625 11.4375 L 6.71875 11.46875 L 6.71875 11.5 L 6.75 11.46875 L 10.90625 13.3125 L 15.15625 15.1875 L 13.53125 10.84375 L 11.9375 6.5625 L 11.90625 6.5625 L 11.90625 6.53125 z "
+       id="path3019" />
+    <path
+       transform="matrix(0.11470637,0.12145165,-0.088438,0.08352626,11.92361,11.142815)"
+       inkscape:transform-center-x="-0.65303443"
+       d="m 30.903804,3.625 -7.334103,4.2343464 -7.334103,4.2343466 0,-8.4686932 0,-8.4686923 7.334103,4.23434635 z"
+       inkscape:randomized="0"
+       inkscape:rounded="0"
+       inkscape:flatsided="false"
+       sodipodi:arg2="1.0471976"
+       sodipodi:arg1="0"
+       sodipodi:r2="4.8894019"
+       sodipodi:r1="9.7788038"
+       sodipodi:cy="3.625"
+       sodipodi:cx="21.125"
+       sodipodi:sides="3"
+       id="path3023"
+       style="color:#000000;fill:#2e3436;fill-opacity:1;fill-rule:nonzero;stroke:#2e3436;stroke-width:3.50741758;marker:none;visibility:visible;display:inline;overflow:visible;enable-background:accumulate;stroke-miterlimit:4;stroke-dasharray:none"
+       sodipodi:type="star" />
+  </g>
+</svg>
diff --git a/icons/verisign.svg b/icons/verisign.svg
new file mode 100644 (file)
index 0000000..cbdb21d
--- /dev/null
@@ -0,0 +1,112 @@
+<?xml version="1.0" encoding="UTF-8" standalone="no"?>
+<!-- Created with Inkscape (http://www.inkscape.org/) -->
+
+<svg
+   xmlns:dc="http://purl.org/dc/elements/1.1/"
+   xmlns:cc="http://creativecommons.org/ns#"
+   xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#"
+   xmlns:svg="http://www.w3.org/2000/svg"
+   xmlns="http://www.w3.org/2000/svg"
+   xmlns:xlink="http://www.w3.org/1999/xlink"
+   xmlns:sodipodi="http://sodipodi.sourceforge.net/DTD/sodipodi-0.dtd"
+   xmlns:inkscape="http://www.inkscape.org/namespaces/inkscape"
+   width="16px"
+   height="16px"
+   id="svg2985"
+   version="1.1"
+   inkscape:version="0.48.4 r9939"
+   sodipodi:docname="verisign.svg"
+   inkscape:export-filename="/home/smcv/src/ikiwiki/icons/verisign.png"
+   inkscape:export-xdpi="90"
+   inkscape:export-ydpi="90">
+  <title
+     id="title3812">approximately the Verisign logo</title>
+  <defs
+     id="defs2987">
+    <linearGradient
+       inkscape:collect="always"
+       id="linearGradient3781">
+      <stop
+         style="stop-color:#000000;stop-opacity:1;"
+         offset="0"
+         id="stop3783" />
+      <stop
+         style="stop-color:#000000;stop-opacity:0;"
+         offset="1"
+         id="stop3785" />
+    </linearGradient>
+    <linearGradient
+       inkscape:collect="always"
+       xlink:href="#linearGradient3781"
+       id="linearGradient3787" />
+  </defs>
+  <sodipodi:namedview
+     id="base"
+     pagecolor="#ffffff"
+     bordercolor="#666666"
+     borderopacity="1.0"
+     inkscape:pageopacity="0.0"
+     inkscape:pageshadow="2"
+     inkscape:zoom="1"
+     inkscape:cx="19.271071"
+     inkscape:cy="3.271264"
+     inkscape:current-layer="layer1"
+     showgrid="true"
+     inkscape:grid-bbox="true"
+     inkscape:document-units="px"
+     inkscape:window-width="1366"
+     inkscape:window-height="717"
+     inkscape:window-x="0"
+     inkscape:window-y="27"
+     inkscape:window-maximized="1" />
+  <metadata
+     id="metadata2990">
+    <rdf:RDF>
+      <cc:Work
+         rdf:about="">
+        <dc:format>image/svg+xml</dc:format>
+        <dc:type
+           rdf:resource="http://purl.org/dc/dcmitype/StillImage" />
+        <dc:title>approximately the Verisign logo</dc:title>
+        <dc:creator>
+          <cc:Agent>
+            <dc:title>Simon McVittie</dc:title>
+          </cc:Agent>
+        </dc:creator>
+        <dc:date>2014</dc:date>
+        <dc:rights>
+          <cc:Agent>
+            <dc:title>ikiwiki basewiki license</dc:title>
+          </cc:Agent>
+        </dc:rights>
+      </cc:Work>
+    </rdf:RDF>
+  </metadata>
+  <g
+     id="layer1"
+     inkscape:label="Layer 1"
+     inkscape:groupmode="layer">
+    <path
+       sodipodi:type="arc"
+       style="color:#000000;fill:none;stroke:#edd400;stroke-width:2.56285746999999997;stroke-linecap:butt;stroke-linejoin:bevel;stroke-miterlimit:4;stroke-opacity:1;stroke-dasharray:none;stroke-dashoffset:0;marker:none;visibility:visible;display:inline;overflow:visible;enable-background:accumulate"
+       id="path3001"
+       sodipodi:cx="7.906188"
+       sodipodi:cy="8.22896"
+       sodipodi:rx="6.734901"
+       sodipodi:ry="6.734901"
+       d="m 14.641089,8.22896 a 6.734901,6.734901 0 1 1 -13.4698019,0 6.734901,6.734901 0 1 1 13.4698019,0 z"
+       transform="matrix(0.77034953,0,0,0.79053893,0.64096934,1.9303724)" />
+    <text
+       xml:space="preserve"
+       style="font-size:21.52570534px;font-style:normal;font-variant:normal;font-weight:500;font-stretch:normal;text-align:start;line-height:125%;letter-spacing:0px;word-spacing:0px;writing-mode:lr-tb;text-anchor:start;fill:#000000;fill-opacity:1;stroke:none;font-family:Inconsolata;-inkscape-font-specification:Inconsolata Medium"
+       x="2.9831085"
+       y="12.96045"
+       id="text3789"
+       sodipodi:linespacing="125%"
+       transform="scale(1.0045059,0.99551431)"><tspan
+         sodipodi:role="line"
+         id="tspan3791"
+         x="2.9831085"
+         y="12.96045">✔</tspan></text>
+  </g>
+</svg>
diff --git a/t/git.t b/t/git.t
index 6d847dfb04d56808dab435a125bc6cbadcfd3af0..0396ae0652a26b5be875ed9a6c733a81f6656117 100755 (executable)
--- a/t/git.t
+++ b/t/git.t
@@ -16,13 +16,14 @@ BEGIN {
                die $@;
        }
 }
-use Test::More tests => 18;
+use Test::More tests => 22;
 
 BEGIN { use_ok("IkiWiki"); }
 
 %config=IkiWiki::defaultconfig();
 $config{rcs} = "git";
 $config{srcdir} = "$dir/src";
+$config{diffurl} = '/nonexistent/cgit/plain/[[file]]';
 IkiWiki::loadplugins();
 IkiWiki::checkconfig();
 
@@ -94,4 +95,26 @@ is($changes[0]{pages}[0]{"page"}, "newdir/test5");
 IkiWiki::rcs_remove("newdir/test5.mdwn");
 IkiWiki::rcs_commit_staged(message => "Remove the 5th page");
 
+# diffurl escaping
+ok(mkdir($config{srcdir}."/diffurl_dir"));
+my $test3 = readfile("t/test1.mdwn");
+writefile('test3.mdwn', $config{srcdir}."/diffurl_dir", $test3);
+IkiWiki::rcs_add("diffurl_dir/test3.mdwn");
+IkiWiki::rcs_commit(
+       file => "diffurl_dir/test3.mdwn",
+       message => "Added a page in diffurl_dir",
+       token => "moo",
+);
+
+@changes = IkiWiki::rcs_recentchanges(5);
+
+is($#changes, 4);
+is($changes[0]{pages}[0]{"page"}, "diffurl_dir/test3");
+
+unlike(
+       $changes[0]{pages}[0]{"diffurl"},
+       qr{%2F}m,
+       q{path separators are preserved when UTF-8scaping filename}
+);
+
 system "rm -rf $dir";
diff --git a/t/syslog.t b/t/syslog.t
new file mode 100644 (file)
index 0000000..ffe8635
--- /dev/null
@@ -0,0 +1,18 @@
+#!/usr/bin/perl
+use warnings;
+use strict;
+use Test::More tests => 5;
+use utf8;
+
+BEGIN { use_ok("IkiWiki"); }
+
+$IkiWiki::config{verbose} = 1;
+$IkiWiki::config{syslog} = 1;
+
+$IkiWiki::config{wikiname} = 'ASCII';
+is(debug('test'), '', 'plain ASCII syslog');
+$IkiWiki::config{wikiname} = 'not ⒶSCII';
+is(debug('test'), '', 'UTF8 syslog');
+my $orig = $IkiWiki::config{wikiname};
+is(debug('test'), '', 'check for idempotency');
+is($IkiWiki::config{wikiname}, $orig, 'unchanged config');
index 1e156eed897890f1e856eb25606ba8057f169975..e3d1feca9ef3d3791ba7e93cf6bad2faf9abecc7 100755 (executable)
@@ -3,7 +3,7 @@ use warnings;
 use strict;
 use Test::More;
 
-my @templates=glob("templates/*.tmpl"), glob("doc/templates/*.mdwn");
+my @templates=(glob("templates/*.tmpl"), glob("doc/templates/*.mdwn"));
 plan(tests => 2*@templates);
 
 use HTML::Template;
diff --git a/underlays/openid-selector/ikiwiki/openid/aol.png b/underlays/openid-selector/ikiwiki/openid/aol.png
new file mode 100644 (file)
index 0000000..d47f5fa
Binary files /dev/null and b/underlays/openid-selector/ikiwiki/openid/aol.png differ
diff --git a/underlays/openid-selector/ikiwiki/openid/goa-account-flickr.png b/underlays/openid-selector/ikiwiki/openid/goa-account-flickr.png
new file mode 100644 (file)
index 0000000..5321642
Binary files /dev/null and b/underlays/openid-selector/ikiwiki/openid/goa-account-flickr.png differ
diff --git a/underlays/openid-selector/ikiwiki/openid/goa-account-google.png b/underlays/openid-selector/ikiwiki/openid/goa-account-google.png
new file mode 100644 (file)
index 0000000..ae1caa8
Binary files /dev/null and b/underlays/openid-selector/ikiwiki/openid/goa-account-google.png differ
diff --git a/underlays/openid-selector/ikiwiki/openid/goa-account-yahoo.png b/underlays/openid-selector/ikiwiki/openid/goa-account-yahoo.png
new file mode 100644 (file)
index 0000000..51e1c11
Binary files /dev/null and b/underlays/openid-selector/ikiwiki/openid/goa-account-yahoo.png differ
diff --git a/underlays/openid-selector/ikiwiki/openid/livejournal.png b/underlays/openid-selector/ikiwiki/openid/livejournal.png
new file mode 100644 (file)
index 0000000..d86ee5e
Binary files /dev/null and b/underlays/openid-selector/ikiwiki/openid/livejournal.png differ
index 0561103843adb093883c0aa437e4ca25fa36b4b2..8b8bbba5de8c3fa07115f6e9aa891ecefb872ccd 100644 (file)
@@ -8,12 +8,12 @@ This code is licenced under the New BSD License.
 var providers_large = {
     google: {
         name: 'Google',
-       icon: 'http://google.com/favicon.ico',
+        icon: 'ikiwiki/openid/goa-account-google.png',
         url: 'https://www.google.com/accounts/o8/id'
     },
     yahoo: {
         name: 'Yahoo',      
-       icon: 'http://yahoo.com/favicon.ico',
+        icon: 'ikiwiki/openid/goa-account-yahoo.png',
         url: 'http://me.yahoo.com/'
     },    
     openid: {
@@ -26,43 +26,31 @@ var providers_large = {
 var providers_small = {
     livejournal: {
         name: 'LiveJournal',
-       icon: 'http://livejournal.com/favicon.ico',
+        icon: 'ikiwiki/openid/livejournal.png',
         label: 'Enter your Livejournal username:',
         url: 'http://{username}.livejournal.com/'
     },
     flickr: {
        name: 'Flickr',        
-       icon: 'http://flickr.com/favicon.ico',
+       icon: 'ikiwiki/openid/goa-account-flickr.png',
        label: 'Enter your Flickr username:',
        url: 'http://flickr.com/photos/{username}/'
     },
     wordpress: {
         name: 'Wordpress',
-       icon: 'https://s2.wp.com/i/favicon.ico',
+       icon: 'ikiwiki/openid/wordpress.png',
         label: 'Enter your Wordpress.com username:',
         url: 'http://{username}.wordpress.com/'
     },
-    myopenid: {
-        name: 'MyOpenID',
-       icon: 'http://myopenid.com/favicon.ico',
-        label: 'Enter your MyOpenID username:',
-        url: 'http://{username}.myopenid.com/'
-    },
-    claimid: {
-        name: 'ClaimID',
-       icon: 'http://claimid.com/favicon.ico',
-        label: 'Enter your ClaimID username:',
-        url: 'http://claimid.com/{username}'
-    },
     aol: {
         name: 'AOL',     
-       icon: 'http://aol.com/favicon.ico',
+        icon: 'ikiwiki/openid/aol.png',
         label: 'Enter your AOL username:',
         url: 'http://openid.aol.com/{username}'
     },
     verisign: {
         name: 'Verisign',
-       icon: 'http://verisign.com/favicon.ico',
+        icon: 'ikiwiki/openid/verisign.png',
         label: 'Enter your Verisign username:',
         url: 'http://{username}.pip.verisignlabs.com/'
     }
diff --git a/underlays/openid-selector/ikiwiki/openid/verisign.png b/underlays/openid-selector/ikiwiki/openid/verisign.png
new file mode 100644 (file)
index 0000000..5120812
Binary files /dev/null and b/underlays/openid-selector/ikiwiki/openid/verisign.png differ
diff --git a/underlays/openid-selector/ikiwiki/openid/wordpress.png b/underlays/openid-selector/ikiwiki/openid/wordpress.png
new file mode 100644 (file)
index 0000000..96e08bd
Binary files /dev/null and b/underlays/openid-selector/ikiwiki/openid/wordpress.png differ