]> git.vanrenterghem.biz Git - git.ikiwiki.info.git/commitdiff
Merge remote-tracking branch 'smcv/ready/no-trails-if-dynamic'
authorJoey Hess <joey@kitenet.net>
Wed, 26 Jun 2013 15:21:35 +0000 (11:21 -0400)
committerJoey Hess <joey@kitenet.net>
Wed, 26 Jun 2013 15:21:35 +0000 (11:21 -0400)
84 files changed:
IkiWiki/Plugin/blogspam.pm
IkiWiki/Plugin/bzr.pm
IkiWiki/Plugin/calendar.pm
IkiWiki/Plugin/comments.pm
IkiWiki/Plugin/meta.pm
IkiWiki/Plugin/notifyemail.pm
IkiWiki/Plugin/osm.pm
IkiWiki/Plugin/theme.pm
Makefile.PL
debian/changelog
doc/bugs/blogspam_marks_me_as_spam_on_ipv6.mdwn [new file with mode: 0644]
doc/bugs/capitalized_attachment_names.mdwn [new file with mode: 0644]
doc/bugs/encoding_issue_in_blogspam_plugin.mdwn [new file with mode: 0644]
doc/bugs/feedpages_does_not_prevent_tags_from_being_aggregated.mdwn [new file with mode: 0644]
doc/bugs/osm_KML_maps_icon_path_have_a_trailing_slash.mdwn
doc/forum/Calendar:_listing_multiple_entries_per_day.mdwn
doc/forum/Can_ikiwiki_be_configured_as_multi_user_blog__63__.mdwn [new file with mode: 0644]
doc/forum/Forward_slashes_being_escaped_as_252F/comment_1_7702cf6d354ab600d6643b075b9f09da._comment [new file with mode: 0644]
doc/forum/How_can_I_prevent_spam__63__.mdwn [new file with mode: 0644]
doc/forum/How_can_I_prevent_spam__63__/comment_1_fd26fb7f1569e8c44ba8262794f938db._comment [new file with mode: 0644]
doc/forum/How_can_I_prevent_spam__63__/comment_2_d098124f005976ee815d25c883bc9106._comment [new file with mode: 0644]
doc/forum/How_can_I_prevent_spam__63__/comment_3_deb434d01aaefa18d2791e48d6c824ae._comment [new file with mode: 0644]
doc/forum/How_do_I_enable_OpenID__63__.mdwn [new file with mode: 0644]
doc/forum/Ikiwiki_themes_for_mobile_devices__63__.mdwn [new file with mode: 0644]
doc/forum/Refresh_or_recreate_style.css__63__.mdwn [new file with mode: 0644]
doc/forum/Refresh_or_recreate_style.css__63__/comment_1_3274be931d0b543c7f7cf641810817aa._comment [new file with mode: 0644]
doc/forum/Translating_ikiwiki_interface.mdwn [new file with mode: 0644]
doc/forum/google_openid_broken__63__.mdwn
doc/forum/web_service_API__44___fastcgi_support.mdwn
doc/git.mdwn
doc/ikiwiki/directive/tag/discussion.mdwn [new file with mode: 0644]
doc/ikiwikiusers.mdwn
doc/news/openid.mdwn
doc/news/version_3.20120725.mdwn [deleted file]
doc/news/version_3.20121016.mdwn [deleted file]
doc/news/version_3.20130504.mdwn [new file with mode: 0644]
doc/news/version_3.20130518.mdwn [new file with mode: 0644]
doc/plugins/contrib/livefyre.mdwn [new file with mode: 0644]
doc/plugins/contrib/mathjax.mdwn [new file with mode: 0644]
doc/plugins/contrib/mediawiki/discussion.mdwn
doc/plugins/contrib/proxies.mdwn
doc/plugins/type/auth.mdwn
doc/plugins/type/bundle.mdwn
doc/plugins/type/chrome.mdwn
doc/plugins/type/comments.mdwn
doc/plugins/type/core.mdwn
doc/plugins/type/date.mdwn
doc/plugins/type/format.mdwn
doc/plugins/type/fun.mdwn
doc/plugins/type/html.mdwn
doc/plugins/type/link.mdwn
doc/plugins/type/meta.mdwn
doc/plugins/type/slow.mdwn
doc/plugins/type/special-purpose.mdwn
doc/plugins/type/tags.mdwn
doc/plugins/type/web.mdwn
doc/plugins/type/widget.mdwn
doc/sandbox.mdwn
doc/style.css
doc/test.mdwn [deleted file]
doc/theme_market.mdwn
doc/themes.mdwn
doc/themes/discussion.mdwn
doc/tips/DreamHost.mdwn
doc/tips/dot_cgi.mdwn
doc/tips/importing_posts_from_wordpress/ikiwiki-wordpress-import.mdwn
doc/tips/mailman_subscription_form.mdwn [new file with mode: 0644]
doc/todo/BTS_integration.mdwn
doc/todo/Calendar:_listing_multiple_entries_per_day_.mdwn
doc/todo/Fenced_code_blocks___40__from_GitHub_Flavored_Markdown__41__.mdwn [new file with mode: 0644]
doc/todo/Restrict_formats_allowed_for_comments.mdwn
doc/todo/Separate_OpenIDs_and_usernames.mdwn
doc/todo/assumes_system_perl.mdwn
doc/todo/calendar_with___34__create__34___links.mdwn [new file with mode: 0644]
doc/todo/calendar_with___34__create__34___links/incomplete_patch.pl [new file with mode: 0644]
doc/todo/fancypodcast.mdwn
doc/todo/toc-with-human-readable-anchors.mdwn [new file with mode: 0644]
doc/todo/translation_links.mdwn [new file with mode: 0644]
doc/translation/discussion.mdwn
doc/users/schmonz.mdwn
doc/wishlist/watched_pages.mdwn [new file with mode: 0644]
ikiwiki.spec
po/ikiwiki.pot
t/map.t

index d32c2f169d643a7db9e9fffc292201a4bf93276e..e48ed729f5439f148e7f70e0d228990cbbe2a0f2 100644 (file)
@@ -53,6 +53,7 @@ sub checkconfig () {
        eval q{
                use RPC::XML;
                use RPC::XML::Client;
+               $RPC::XML::ENCODING = 'utf-8';
        };
        error $@ if $@;
 }
index 72552abccaa96212c5f71d48cefcbb1b21e4498b..99a07d2c0eb2afa5512f6fc96043df6ff24171ff 100644 (file)
@@ -195,7 +195,7 @@ sub rcs_add ($) {
 sub rcs_remove ($) {
        my ($file) = @_;
 
-       my @cmdline = ("bzr", "rm", "--force", "--quiet", "$config{srcdir}/$file");
+       my @cmdline = ("bzr", "rm", "--quiet", "$config{srcdir}/$file");
        if (system(@cmdline) != 0) {
                warn "'@cmdline' failed: $!";
        }
index d443198f69618f28e37821766731b50bc2599306..8ca6dd82680171d8ebae5f88ac9053c327e0ad3d 100644 (file)
@@ -86,8 +86,10 @@ sub format_month (@) {
                my $year  = $date[5] + 1900;
                my $mtag  = sprintf("%02d", $month);
 
-               # Only one posting per day is being linked to.
-               $linkcache{"$year/$mtag/$mday"} = $p;
+               if (! $linkcache{"$year/$mtag/$mday"}) {
+                       $linkcache{"$year/$mtag/$mday"} = [];
+               }
+               push(@{$linkcache{"$year/$mtag/$mday"}}, $p);
        }
                
        my $pmonth = $params{month} - 1;
@@ -221,11 +223,38 @@ EOF
                                $tag='month-calendar-day-link';
                        }
                        $calendar.=qq{\t\t<td class="$tag $downame{$wday}">};
-                       $calendar.=htmllink($params{page}, $params{destpage}, 
-                               $linkcache{$key},
-                               noimageinline => 1,
-                               linktext => $day,
-                               title => pagetitle(IkiWiki::basename($linkcache{$key})));
+                       if (scalar(@{$linkcache{$key}}) == 1) {
+                               # Only one posting on this page
+                               my $page = $linkcache{$key}[0];
+                               $calendar.=htmllink($params{page}, $params{destpage}, 
+                                       $page,
+                                       noimageinline => 1,
+                                       linktext => $day,
+                                       title => pagetitle(IkiWiki::basename($page)));
+                       }
+                       else {
+                               $calendar.=qq{<div class='popup'>$day<div class='balloon'>};
+                               # Several postings on this page
+                               $calendar.=qq{<ul>};
+                               foreach my $page (@{$linkcache{$key}}) {
+                                       $calendar.= qq{\n\t\t\t<li>};
+                                       my $title;
+                                       if (exists $pagestate{$page}{meta}{title}) {
+                                               $title = "$pagestate{$page}{meta}{title}";
+                                       }
+                                       else {
+                                               $title = pagetitle(IkiWiki::basename($page));
+                                       }
+                                       $calendar.=htmllink($params{page}, $params{destpage}, 
+                                               $page,
+                                               noimageinline => 1,
+                                               linktext => $title,
+                                               title => $title);
+                                       $calendar.= '</li>';
+                               }
+                               $calendar.=qq{\n\t\t</ul>};
+                               $calendar.=qq{</div></div>};
+                       }
                        $calendar.=qq{</td>\n};
                }
                else {
index c00bf52752e9326a3ffc40855ed8b130dced74ce..1ef79a27a958a77dde14f75dd34b1b5c75dd5763 100644 (file)
@@ -90,6 +90,15 @@ sub getsetup () {
                        safe => 0,
                        rebuild => 0,
                },
+               comments_allowformats => {
+                       type => 'string',
+                       default => '',
+                       example => 'mdwn txt',
+                       description => 'Restrict formats for comments to (no restriction if empty)',
+                       safe => 1,
+                       rebuild => 0,
+               },
+
 }
 
 sub checkconfig () {
@@ -101,6 +110,8 @@ sub checkconfig () {
                unless defined $config{comments_closed_pagespec};
        $config{comments_pagename} = 'comment_'
                unless defined $config{comments_pagename};
+       $config{comments_allowformats} = ''
+               unless defined $config{comments_allowformats};
 }
 
 sub htmlize {
@@ -128,12 +139,18 @@ sub safeurl ($) {
        }
 }
 
+sub isallowed ($) {
+    my $format = shift;
+    return ! $config{comments_allowformats} || $config{comments_allowformats} =~ /\b$format\b/;
+}
+
 sub preprocess {
        my %params = @_;
        my $page = $params{page};
 
        my $format = $params{format};
-       if (defined $format && ! exists $IkiWiki::hooks{htmlize}{$format}) {
+       if (defined $format && (! exists $IkiWiki::hooks{htmlize}{$format} ||
+                               ! isallowed($format))) {
                error(sprintf(gettext("unsupported page format %s"), $format));
        }
 
@@ -332,7 +349,7 @@ sub editcomment ($$) {
 
        my @page_types;
        if (exists $IkiWiki::hooks{htmlize}) {
-               foreach my $key (grep { !/^_/ } keys %{$IkiWiki::hooks{htmlize}}) {
+               foreach my $key (grep { !/^_/ && isallowed($_) } keys %{$IkiWiki::hooks{htmlize}}) {
                        push @page_types, [$key, $IkiWiki::hooks{htmlize}{$key}{longname} || $key];
                }
        }
index 421f1dc86a83d33ac823f9989ad9e42c6dea12c9..7ea70b5d19e17595e2a6b611dee1178347da7a81 100644 (file)
@@ -107,12 +107,12 @@ sub preprocess (@) {
                # fallthrough
        }
        elsif ($key eq 'license') {
-               push @{$metaheaders{$page}}, '<link rel="license" href="#page_license" />';
+               push @{$metaheaders{$page}}, '<link rel="license" href="#pagelicense" />';
                $pagestate{$page}{meta}{license}=$value;
                return "";
        }
        elsif ($key eq 'copyright') {
-               push @{$metaheaders{$page}}, '<link rel="copyright" href="#page_copyright" />';
+               push @{$metaheaders{$page}}, '<link rel="copyright" href="#pagecopyright" />';
                $pagestate{$page}{meta}{copyright}=$value;
                return "";
        }
index 2c1775f2e81df281a7c7769220acc26ade476cdf..b50a22a00c2e0bc6179a21b22b987d8241282afb 100644 (file)
@@ -78,6 +78,7 @@ sub anonsubscribe ($$) {
 sub notify (@) {
        my @files=@_;
        return unless @files;
+       return if $config{rebuild};
 
        eval q{use Mail::Sendmail};
        error $@ if $@;
index a7baa5f2b968ebb0464a787be7371a26a2f98423..c9650d014aa1348f9c83efb77e87c76f20620452 100644 (file)
@@ -192,6 +192,7 @@ sub process_waypoint {
                }
        }
        $icon = urlto($icon, $dest, 1);
+       $icon =~ s!/*$!!; # hack - urlto shouldn't be appending a slash in the first place
        $tag = '' unless $tag;
        register_rendered_files($map, $page, $dest);
        $pagestate{$page}{'osm'}{$map}{'waypoints'}{$name} = {
index ee94547e90c51dad608b020e1be6bc0a434d38d7..9b84ea7f023d10c6db947f136adb4ed8b8ec72e0 100644 (file)
@@ -9,6 +9,7 @@ sub import {
        hook(type => "getsetup", id => "theme", call => \&getsetup);
        hook(type => "checkconfig", id => "theme", call => \&checkconfig);
        hook(type => "needsbuild", id => "theme", call => \&needsbuild);
+       hook(type => "pagetemplate", id => "theme", call => \&pagetemplate);
 }
 
 sub getsetup () {
@@ -63,4 +64,12 @@ sub needsbuild ($) {
        return $needsbuild;
 }
 
+sub pagetemplate (@) {
+       my %params=@_;
+       my $template=$params{template};
+       if (exists $config{theme} && length $config{theme})  {
+               $template->param("theme_$config{theme}" => 1);
+       }
+}
+
 1
index ef29a950c777b8e3c7b74821790a1b184be28c3b..f1df8bcd3f2dbfa463e3e182c4a295f5b547ff7d 100755 (executable)
@@ -96,7 +96,7 @@ underlay_install:
                install -d $(DESTDIR)$(PREFIX)/share/ikiwiki/$$theme; \
                for file in $$theme/*; do \
                        if echo "$$file" | grep -q style.css; then \
-                               (cat doc/style.css; cat $$theme/base.css 2>/dev/null; cat $$file) >> $(DESTDIR)$(PREFIX)/share/ikiwiki/$$theme/style.css; \
+                               (cat doc/style.css; cat $$theme/base.css 2>/dev/null; cat $$file) > $(DESTDIR)$(PREFIX)/share/ikiwiki/$$theme/style.css; \
                        elif echo "$$file" | grep -q base.css; then \
                                :; \
                        elif [ -f "$$file" ]; then \
index 1657ffcb608c53c51be26462ee05569ac8b4cfaa..e817deb9bbe8426637a3b29cbecde4eaee2c6310 100644 (file)
@@ -1,12 +1,42 @@
-ikiwiki (3.20130213) UNRELEASED; urgency=low
+ikiwiki (3.20130519) UNRELEASED; urgency=low
+
+  * 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.
+
+ -- Joey Hess <joeyh@debian.org>  Sun, 23 Jun 2013 14:02:01 -0400
+
+ikiwiki (3.20130518) unstable; urgency=low
+
+  * Fix test suite to not fail when XML::Twig is not installed.
+    Closes: #707436
+  * theme: Now <TMPL_IF THEME_$NAME> can be used in all templates when
+    a theme is enabled.
+  * notifyemail: Fix bug that caused duplicate emails to be sent when
+    site was rebuilt.
+  * bzr: bzr rm no longer has a --force option, remove
+
+ -- Joey Hess <joeyh@debian.org>  Sat, 18 May 2013 16:28:21 -0400
+
+ikiwiki (3.20130504) unstable; urgency=low
 
   * Allow dots in directive parameter names. (tango)
   * Add missing plugin section, and deal with missing sections with a warning.
   * Detect plugins with a broken getsetup and warn.
   * map: Correct reversion introduced in version 3.20110225 that could
     generate invalid html. (smcv)
+  * Makefile.PL: overwrite theme style.css instead of appending
+    (Thanks, Mikko Rapeli)
+  * meta: Fix anchors used to link to the page's license and copyright.
+    Closes: #706437
 
- -- Joey Hess <joeyh@debian.org>  Fri, 15 Feb 2013 17:23:12 -0400
+ -- Joey Hess <joeyh@debian.org>  Sat, 04 May 2013 23:47:21 -0400
 
 ikiwiki (3.20130212) unstable; urgency=low
 
diff --git a/doc/bugs/blogspam_marks_me_as_spam_on_ipv6.mdwn b/doc/bugs/blogspam_marks_me_as_spam_on_ipv6.mdwn
new file mode 100644 (file)
index 0000000..9b415a8
--- /dev/null
@@ -0,0 +1,8 @@
+I just got this message trying to post to this wiki:
+
+    Error: Sorry, but that looks like spam to blogspam: No reverse DNS entry for 2001:1928:1:9::1
+
+So yeah, it seems I have no reverse DNS for my IPv6 address, which may
+be quite common for emerging IPv6 deployments...
+
+This may be related to [[blogspam_options whitelist vs. IPv6?]].
diff --git a/doc/bugs/capitalized_attachment_names.mdwn b/doc/bugs/capitalized_attachment_names.mdwn
new file mode 100644 (file)
index 0000000..b10781b
--- /dev/null
@@ -0,0 +1,14 @@
+Given an uploaded image via: \[\[!img NAME.svg alt="image"\]\]
+
+Viewing the generated page shows the following error:
+
+"\[\[!img Error: failed to read name.svg: Exception 420: no decode delegate for this image format `/home/user/path/name.svg' @ error/svg.c/ReadSVGImage/2815\]\]"
+
+The caps in the image title were somehow converted to small letters and then the image is saved as a directory.  Very puzzling.  
+I get the same error when image names are small letters.
+
+The error also occurs with png images.  
+
+How do I fix this?
+
+Later investigation ... I got around the problem by creating the mark-up in a new directory.  However, if I try to create a new directory with the same name as the directory containing the problem code, the problem re-emerges -- the old directory is apparently not overwritten.  Perhaps this is an issue with the git storage.    
diff --git a/doc/bugs/encoding_issue_in_blogspam_plugin.mdwn b/doc/bugs/encoding_issue_in_blogspam_plugin.mdwn
new file mode 100644 (file)
index 0000000..92318d1
--- /dev/null
@@ -0,0 +1,34 @@
+[[!tag patch]]
+
+<pre>
+From 5ad35b2805ca50478f07d810e57e7c9b8f4eddea Mon Sep 17 00:00:00 2001
+From: Changaco &lt;changaco@changaco.net>
+Date: Tue, 4 Jun 2013 02:54:35 +0200
+Subject: [PATCH] fix encoding issue in blogspam plugin
+
+RPC::XML uses ascii as default encoding, we have to tell it to use utf8.
+
+Without this, ikiwiki returns "failed to get response from blogspam server"
+every time a non-ascii character is used in a content that needs checking.
+
+---
+ IkiWiki/Plugin/blogspam.pm | 1 +
+ 1 file changed, 1 insertion(+)
+
+diff --git a/IkiWiki/Plugin/blogspam.pm b/IkiWiki/Plugin/blogspam.pm
+index d32c2f1..e48ed72 100644
+--- a/IkiWiki/Plugin/blogspam.pm
++++ b/IkiWiki/Plugin/blogspam.pm
+@@ -53,6 +53,7 @@ sub checkconfig () {
+       eval q{
+               use RPC::XML;
+               use RPC::XML::Client;
++              $RPC::XML::ENCODING = 'utf-8';
+       };
+       error $@ if $@;
+ }
+-- 
+1.8.3
+</pre>
+
+[[done]] --[[Joey]] 
diff --git a/doc/bugs/feedpages_does_not_prevent_tags_from_being_aggregated.mdwn b/doc/bugs/feedpages_does_not_prevent_tags_from_being_aggregated.mdwn
new file mode 100644 (file)
index 0000000..a004154
--- /dev/null
@@ -0,0 +1,32 @@
+I added a feedpages directive to `blog/index.mdwn` to not pick up anything tagged `tags/random/hidden` yet that still happenend.
+
+    ~git/richardhartmann.de/blog % grep hidden index.mdwn
+    \[[!inline pages="./posts/*/*/* and !*/Discussion" feedpages="./posts/*/*/* and !*/Discussion and not tagged(tags/random/hidden)" show="10" actions=yes rootpage="blog"]]
+    ~git/richardhartmann.de/blog % grep hidden posts/2013/05/17-Debian_Release_Critical_Bug_report_for_Week_20.mdwn
+    \[[!tag tags/tech/floss/debian tags/tech/floss/debian/rc-stats/8.0-jessie tags/random/hidden]]
+    ~git/richardhartmann.de/blog %
+
+If you need more information, please let me know.
+
+Richard
+
+> I don't think this is a bug. You have a syntax error in your pagespec:
+> "not" is not a recognised keyword in [[pagespecs|ikiwiki/pagespec]],
+> so `and not tagged(...)` should be `and !tagged(...)`. Presumably inline
+> falls back to `pages` when `feedpages` doesn't work.
+>
+> By posting the pagespec here with insufficient escaping (which I've fixed)
+> you caused *this* ikiwiki instance's HTML to contain an error message
+> illustrating that syntax error :-)
+>
+>     <span class="error">Error: syntax error in pagespec "(./posts/*/*/* and !*/Discussion) and (./posts/*/*/* and !*/Discussion and not tagged(tags/random/hidden))"</span>
+>
+> [[done]]. --[[smcv]]
+
+> > As per IRC: Thanks. As an aside, shouldn't this ikiwiki instance ignore directives in normal text? The problem may be non-trivial, but still... -- Richard
+
+>>> "Normal text" is exactly where directives go, so, not really.
+>>> If you mean verbatim text (e.g. indentation in Markdown): the fact that
+>>> directives still expand to HTML, which is then treated as verbatim, is an
+>>> unfortunate result of how ikiwiki interacts with pages' markup languages
+>>> (directives and wikilinks happen before markup is converted to HTML). --[[smcv]]
index 0677d0e74725cbac67a11c18ef95038d3f8c4cc1..a3a88d138b8098326485c51403f5c202a099a609 100644 (file)
@@ -30,3 +30,5 @@ index a7baa5f..c9650d0 100644
 """]]
 
 I'm not writing this to a branch out of sheer shame of my misunderstanding. ;) There also may be a workaround that could be done in Nginx too. --[[anarcat]]
+
+> [[applied|done]], but I'm not happy with this either --[[Joey]]
index 251cd6d9f9cfb22e5c92651dce6f02a426308316..c3ecf36bece9652c39df300cda6e13b408f0a7f8 100644 (file)
@@ -17,3 +17,5 @@ and a suitable whilst loop looks to be all that's needed...
 Any pointers appreciated.
 
 A [[!taglink patch]] has been proposed in [comment](#comment-d6f94e2b779d1c038b6359aad79ed14b)
+
+> This has been applied. --[[Joey]]
diff --git a/doc/forum/Can_ikiwiki_be_configured_as_multi_user_blog__63__.mdwn b/doc/forum/Can_ikiwiki_be_configured_as_multi_user_blog__63__.mdwn
new file mode 100644 (file)
index 0000000..118b534
--- /dev/null
@@ -0,0 +1,7 @@
+All the ikiwiki blogs I have seen have a single user blog. Is it possible to give every user a blog, where they can create their own pages in their own directory = based on their user name? 
+
+I feel that a wiki might give more options in the way users share and collaborate when compared to a blog engine (like Word Press in multi user format)
+
+Is this the best place to post a question like this? There doesn't seem to be much traffic in this forum
+Thanks for your help
+Richard
diff --git a/doc/forum/Forward_slashes_being_escaped_as_252F/comment_1_7702cf6d354ab600d6643b075b9f09da._comment b/doc/forum/Forward_slashes_being_escaped_as_252F/comment_1_7702cf6d354ab600d6643b075b9f09da._comment
new file mode 100644 (file)
index 0000000..7c9ccbc
--- /dev/null
@@ -0,0 +1,12 @@
+[[!comment format=mdwn
+ username="https://www.google.com/accounts/o8/id?id=AItOawm6gCEo_Z36OJ7x5kyZn52lEVvyjn3zSUc"
+ nickname="Ángel"
+ subject="comment 1"
+ date="2013-05-31T16:03:03Z"
+ content="""
+Simply add the NE (No escape) flag:
+
+RewriteEngine on
+RewriteCond %{HTTP_HOST} ^www\.ciffer\.net$
+RewriteRule /(.*) http://ciffer.net/$1 [L,R,NE]
+"""]]
diff --git a/doc/forum/How_can_I_prevent_spam__63__.mdwn b/doc/forum/How_can_I_prevent_spam__63__.mdwn
new file mode 100644 (file)
index 0000000..44e3192
--- /dev/null
@@ -0,0 +1,17 @@
+I am getting continuous spam like this:
+
+    discussion  85.25.146.11  web  11:02:19 05/17/13  2rand[0,1,1]
+    discussion  85.25.146.11  web  11:02:13 05/17/13  2rand[0,1,1]
+
+The bot uses an IP address as the username and puts '2rand[0,1,1]' as comment text.
+
+I do not have a page 'discussion' in use, so I have redirected this page with an apache2
+Alias to a static page, just in case anyone stumbles on it.  This means it cannot really 
+be edited via the web. However the bots that post 
+this spam are evidently not opening the page to edit it, but merely sending a cgi request 
+as if they had edited the page.  The result is that no damage is done on the site and no 
+benefit is achieved for the spammer since google cannot see the result.  However, the 
+logs are stuffed with spurious entries and a page is constantly recompiled, which wastes 
+resources.  
+
+Is there some way to reject edits that do not arise from an established session?
diff --git a/doc/forum/How_can_I_prevent_spam__63__/comment_1_fd26fb7f1569e8c44ba8262794f938db._comment b/doc/forum/How_can_I_prevent_spam__63__/comment_1_fd26fb7f1569e8c44ba8262794f938db._comment
new file mode 100644 (file)
index 0000000..a729328
--- /dev/null
@@ -0,0 +1,19 @@
+[[!comment format=mdwn
+ username="http://joeyh.name/"
+ nickname="joey"
+ subject="comment 1"
+ date="2013-05-17T17:55:46Z"
+ content="""
+Normally ikiwiki requires a valid session cookie of a logged in user to edit pages. It sounds like you may have the opendiscussion or anonok plugins enabled, which allows anyone to edit without logging in. Recommend disabling them.
+
+Since you know the spammer's IP, put it into ikiwiki.setup:
+
+<pre>
+banned_users:
+  - ip(85.25.146.11)
+</pre>
+
+If the user was logging in, you could also put their username in the ban list.
+
+You can also try enabling the blogspam plugin.
+"""]]
diff --git a/doc/forum/How_can_I_prevent_spam__63__/comment_2_d098124f005976ee815d25c883bc9106._comment b/doc/forum/How_can_I_prevent_spam__63__/comment_2_d098124f005976ee815d25c883bc9106._comment
new file mode 100644 (file)
index 0000000..53e7433
--- /dev/null
@@ -0,0 +1,16 @@
+[[!comment format=mdwn
+ username="http://claimid.com/richard-lyons"
+ nickname="richard-lyons"
+ subject="comment 2"
+ date="2013-05-17T20:56:23Z"
+ content="""
+I did indeed have opendiscussion active.  I shall wait to see what happens after disabling it.
+
+The bots seem to make 5 consecutive edits at short intervals (around 2 minutes) using an IP 
+address as a username.  I do not know if the IP is the one from which they work.  There are 
+usually two or three sets of five edits using different IP addresses as username in each hour.
+
+I did try blocking specific IPs but they constantly change.
+
+It would be good if blocking could match a regexp, but as far as I can see this is not an option,
+"""]]
diff --git a/doc/forum/How_can_I_prevent_spam__63__/comment_3_deb434d01aaefa18d2791e48d6c824ae._comment b/doc/forum/How_can_I_prevent_spam__63__/comment_3_deb434d01aaefa18d2791e48d6c824ae._comment
new file mode 100644 (file)
index 0000000..64783be
--- /dev/null
@@ -0,0 +1,8 @@
+[[!comment format=mdwn
+ username="http://claimid.com/richard-lyons"
+ nickname="richard-lyons"
+ subject="SOLVED -- How can I prevent spam?"
+ date="2013-05-18T08:13:19Z"
+ content="""
+I can now confirm that this particular attack has stopped after removing the opendiscussion plugin.
+"""]]
diff --git a/doc/forum/How_do_I_enable_OpenID__63__.mdwn b/doc/forum/How_do_I_enable_OpenID__63__.mdwn
new file mode 100644 (file)
index 0000000..a4e1a45
--- /dev/null
@@ -0,0 +1 @@
+I'm trying to set up a new ikiwiki based blog and I want commentors to be able to log in with OpenID.  To enable OpenID I installed Net::OpenID::Consumer, and enabled the openid plugin in my blog.setup file and ran the ikiwiki --setup command.  Despite doing that I still only see the username and password in the login screen.  What am I missing?
diff --git a/doc/forum/Ikiwiki_themes_for_mobile_devices__63__.mdwn b/doc/forum/Ikiwiki_themes_for_mobile_devices__63__.mdwn
new file mode 100644 (file)
index 0000000..dc1b31c
--- /dev/null
@@ -0,0 +1,7 @@
+Has anyone else created ikiwiki themes for mobile devices like phones and tablets?
+
+I've been using Blueview theme for a few years and finally tried to adapt the theme for my phone.
+My local.css is [here](http://mcfrisk.kapsi.fi/local.css), and my hobby web page full of images and videos [here](http://mcfrisk.kapsi.fi/skiing/).
+
+Previously I also had problems like wasted screen space, big minimum width and images not scaled down to the CSS element. Those got fixed as well.
+Would be nice if others could test that and maybe share their setups.
diff --git a/doc/forum/Refresh_or_recreate_style.css__63__.mdwn b/doc/forum/Refresh_or_recreate_style.css__63__.mdwn
new file mode 100644 (file)
index 0000000..262b0e3
--- /dev/null
@@ -0,0 +1,40 @@
+I was trying to use plain blueview theme but that's not what I see in the installed style.css:
+
+    ~/src/ikiwiki/themes/blueview$ grep bzed style.css
+    /*    bzed theme for ikiwiki
+    ~/src/ikiwiki/themes/blueview$ wc -l style.css
+    281 style.css
+    $ grep bzed ~/www/style.css
+    /*    bzed theme for ikiwiki
+    /*    bzed theme for ikiwiki
+    /*    bzed theme for ikiwiki
+    /*    bzed theme for ikiwiki
+    /*    bzed theme for ikiwiki
+    /*    bzed theme for ikiwiki
+    /*    bzed theme for ikiwiki
+    /*    bzed theme for ikiwiki
+    /*    bzed theme for ikiwiki
+    /*    bzed theme for ikiwiki
+    $ wc -l ~/www/style.css
+    7913
+
+I have installed ikiwiki to my home directory on the shared server and it seems the big css file is there too:
+
+    $ grep bzed ~/bin/share/ikiwiki/themes/blueview/style.css 
+    /*    bzed theme for ikiwiki
+    /*    bzed theme for ikiwiki
+    /*    bzed theme for ikiwiki
+    /*    bzed theme for ikiwiki
+    /*    bzed theme for ikiwiki
+    /*    bzed theme for ikiwiki
+    /*    bzed theme for ikiwiki
+    /*    bzed theme for ikiwiki
+    /*    bzed theme for ikiwiki
+    /*    bzed theme for ikiwiki
+    $ wc -l ~/bin/share/ikiwiki/themes/blueview/style.css 
+    7913
+
+Is the style.css really supposed to be that big?
+If not, how to create it from scratch?
+
+Reason why I'm debugging the css is that I'd like to make it better on small handset screens, like drop all margins, inline or hide sidebar etc. Chromium shows that the processed css is quite a mess.
diff --git a/doc/forum/Refresh_or_recreate_style.css__63__/comment_1_3274be931d0b543c7f7cf641810817aa._comment b/doc/forum/Refresh_or_recreate_style.css__63__/comment_1_3274be931d0b543c7f7cf641810817aa._comment
new file mode 100644 (file)
index 0000000..608dca0
--- /dev/null
@@ -0,0 +1,8 @@
+[[!comment format=mdwn
+ username="http://mcfrisk.myopenid.com/"
+ nickname="mikko.rapeli"
+ subject="bug/feature in Makefile.PL"
+ date="2013-03-30T11:53:41Z"
+ content="""
+Theme style.css files were appended when installing in Makefile.PL. IMO overwriting the destination files is more correct. Sent a patch to Joey.
+"""]]
diff --git a/doc/forum/Translating_ikiwiki_interface.mdwn b/doc/forum/Translating_ikiwiki_interface.mdwn
new file mode 100644 (file)
index 0000000..4003302
--- /dev/null
@@ -0,0 +1,2 @@
+I am using ikiwiki for a spanish language wiki. I've read the [[translation]] page and [[plugins/po]] plugin page but it is not completely clear to me. As I understand it the po plugin is the recommended way to create translated versions of existing pages in your wiki based on a master language.  But I actually don't need that as myself and other users already edit the wiki in spanish.  What I would actually like is to have the ikiwiki interface itself translated into spanish. 
+Is it possible to have my wiki always appear in spanish? I can see that the debian package already includes po files for spanish.  How do i activate the spanish translation permanently? Did I miss something obvious?
index 96ba2d79145adbc9c2fdcaba05201a380b57ce6c..d25d8fe4cc3d29d29fa7176a9ee833a58f2e1e17 100644 (file)
@@ -4,6 +4,9 @@ directly to sign into ikiwiki. Just use, for example,
 
 > This seems to work fine if you use the profile directly as an OpenID.  It doesn't seem to work with delegation.  From that I can see, this is a deliberate decision by Google for security reasons.  See the response [here](http://groups.google.com/group/google-federated-login-api/browse_thread/thread/825067789537568c/23451a68c8b8b057?show_docid=23451a68c8b8b057). -- [[Will]]
 
+### adding the GMail OpenID as an admin is unhandy
+Adding the non-human-friendly OpenID from Gmail as an admin for ikiwiki (if you haven't set up a profile with a readabe URL) is unhandy; first, you need to discover the URL, for example, by making a web edit with it (like me [here](http://source.ikiwiki.branchable.com/?p=source.git;a=search;s=https://www.google.com/accounts/o8/id%3Fid%3DAItOawl3JW_Ow4xMqj98Ig1vwGx_AnjUSsgwE8E;st=author)), and then copy the URL to ikiwiki.setup. --Ivan Z.
+
 ## historical discussion
 
 when I login via to this wiki (or ours) via Google's OpenID, I get this error:
index 4a78fb932e92ba6380d05cff0f97fe0728bc1470..84b227eef1980d8b948f4ea43dbb8a74800efacb 100644 (file)
@@ -11,3 +11,8 @@ Anyway - I've realised that a big part of the interactive todo lists stuff is tr
 Second, and in a way related, I've been mooting hacking fastcgi support into ikiwiki. Essentially one ikiwiki.cgi process would persist and serve CGI-ish requests on stdin/stdout. The initial content-scanning and dependency generation would happen once and not need to be repeated for future requests. Although, all state-changing operations would need to be careful to ensure the in-memory models were accurate. Also, I don't know how suited the data structures would be for persistence, since the current model is build em up, throw em away, they might not be space-efficient enough for persistence.
 
 If I did attempt this, I would want to avoid restructuring things in a way which would impair ikiwiki's core philosophy of being a static compiler. -- [[Jon]]
+
+> This is quite interesting! There is a related discussion about FastCGI
+> support (and therefore better support for Nginx, for example) in
+> [[todo/fastcgi_or_modperl_installation_instructions/]]... --
+> [[anarcat]]
index 25a360efdcef2c28218f0389c3bb8df6fe80ab1a..b743f6175e9c28db46165f5c710076af4b13fc93 100644 (file)
@@ -76,6 +76,7 @@ think about merging them. This is recommended. :-)
 * [[ttw]] `git://github.com/ttw/ikiwiki.git`
 * [[anarcat]] `git://src.anarcat.ath.cx/ikiwiki`
 * anderbubble `git://civilfritz.net/ikiwiki.git`
+* frioux `git://github.com/frioux/ikiwiki`
 
 ## branches
 
diff --git a/doc/ikiwiki/directive/tag/discussion.mdwn b/doc/ikiwiki/directive/tag/discussion.mdwn
new file mode 100644 (file)
index 0000000..23352eb
--- /dev/null
@@ -0,0 +1,13 @@
+# Tags in HTML pages
+
+http://rhombus-tech.net is an ikiwiki site where the hardware development is expanding: there are now four hardware projects each of which has its own news page.  For convenience (putting in images for example), the pages have to use HTML not markdown or any other non-HTML format.
+
+However as there are quite a lot of them it would make sense to have an overview page saying "news reports", and that page to be auto-generated because every individual news page is tagged.
+
+... except the news pages are written in HTML, not any markup language into which a tag can be placed.
+
+question: what is the directive which allows an HTML page to have embedded within it a markup "tag"?
+
+> You can use the tag directive in `.html` pages, just like in `.mdwn` pages. This is if you're using
+> the default html plugin. If you instead use the rawhtml plugin, ikiwiki just copies your html files
+> and directives in them won't work. --[[Joey]]
index 3098145582c3c84b5ccf1600d9b849963caa5648..ecba46e03227a4bb28a25e1886416c82426c1451 100644 (file)
@@ -19,7 +19,7 @@ Projects & Organizations
 ========================
 
 * [This wiki](http://ikiwiki.info) (of course!)
-<!-- * [NetBSD wiki](http://wiki.netbsd.org) -->
+* [NetBSD wiki](http://wiki.netbsd.org)
 * The [GNU Hurd](http://www.gnu.org/software/hurd/)
 * [DragonFly BSD](http://www.dragonflybsd.org/)
 * [Monotone](http://wiki.monotone.ca/)
@@ -87,6 +87,10 @@ Projects & Organizations
 * [The Open TV White Space Project](http://opentvws.org)
 * [The RS-232 Club](http://rs232club.org)
 * [FusionInventory project](http://www.fusioninventory.org)
+* FabLab Deventer i.o.
+* [Börn og tónlist](http://bornogtonlist.net/) - an Icelandic open-content site, primarily for kindergarten teachers, about music and music-related activites with children. Migrated from MediaWiki to IkiWiki in June 2013. Heavily changed appearance with only minimal changes to page.tmpl.
+* [Réseaulibre.ca](http://wiki.reseaulibre.ca) - a mesh project in Montréal, most data is stored in the wiki, including IP address allocation and geographic data. Features map ([[plugins/osm]]) integration.
+* [Foufem](http://foufem.orangeseeds.org/) - Foufem, a feminist hackerspace
 
 Personal sites and blogs
 ========================
@@ -189,4 +193,6 @@ Personal sites and blogs
 * [[Martín Ferrari's homepage|http://tincho.org/]] and [[blog|http://blog.tincho.org/]]
 * [WikiAtoBR](http://wiki.hi.ato.br) Open, free and annoymous wiki. No need for account registering and login. It is Brazilian so it is in Portuguese.
 * [Manifesto](http://manifesto.hi.ato.br) Open, free and annoymous blog. No need for account registering and login. It is Brazilian so it is in Portuguese.
-
+ * [Z is for Zombies](http://blog.zouish.org/) — personal blog/site of Francesca Ciceri
+* Julien Lefrique's [homepage](http://julien.lefrique.name/), hosted on [GitHub pages](https://github.com/jlefrique/jlefrique.github.com) with CGI disabled
+* [Anarcat's homepage](http://anarcat.ath.cx/) - with a custom [[theme|theme_market]]
index b13e821468844ed5a09de160c6748fa33a659f38..0f4b8b5bf560d2299fa5c4722458641d1b1ab880 100644 (file)
@@ -10,4 +10,4 @@ log back in, try out the OpenID signup process if you don't already have an
 OpenID, and see how OpenID works for you. And let me know your feelings about
 making such a switch. --[[Joey]]
 
-[[!poll 69 "Accept only OpenID for logins" 21 "Accept only password logins" 44 "Accept both"]]
+[[!poll 70 "Accept only OpenID for logins" 21 "Accept only password logins" 47 "Accept both"]]
diff --git a/doc/news/version_3.20120725.mdwn b/doc/news/version_3.20120725.mdwn
deleted file mode 100644 (file)
index 08e2c77..0000000
+++ /dev/null
@@ -1,13 +0,0 @@
-ikiwiki 3.20120725 released with [[!toggle text="these changes"]]
-[[!toggleable text="""
-   * recentchangesdiff: When diffurl is not set, provide inline diffs
-     in the recentchanges page, with visibility toggleable via javascript.
-     Thanks, Antoine Beaupré
-   * Split CFLAGS into words when building wrapper. Closes: #[682237](http://bugs.debian.org/682237)
-   * osm: Avoid calling urlto before generated files are registered.
-     Thanks, Philippe Gauthier and Antoine Beaupré
-   * osm: Add osm\_openlayers\_url configuration setting.
-     Thanks, Genevieve
-   * osm: osm\_layers can be used to configured the layers displayed on the map.
-     Thanks, Antoine Beaupré
-   * comments: Remove ipv6 address specific code."""]]
\ No newline at end of file
diff --git a/doc/news/version_3.20121016.mdwn b/doc/news/version_3.20121016.mdwn
deleted file mode 100644 (file)
index 62cb397..0000000
+++ /dev/null
@@ -1,17 +0,0 @@
-ikiwiki 3.20121016 released with [[!toggle text="these changes"]]
-[[!toggleable text="""
-   * monochrome: New theme, contributed by Jon Dowland.
-   * rst: Ported to python 3, while still also being valid python 2.
-     Thanks, W. Trevor King
-   * Try to avoid a situation in which so many ikiwiki cgi wrapper programs
-     are running, all waiting on some long-running thing like a site rebuild,
-     that it prevents the web server from doing anything else. The current
-     approach only avoids this problem for GET requests; if multiple cgi's
-     run GETs on a site at the same time, one will display a "please wait"
-     page for a configurable number of seconds, which then redirects to retry.
-     To enable this protection, set cgi\_overload\_delay to the number of
-     seconds to wait. This is not enabled by default.
-   * Add back a 1em margin between archivepage divs.
-   * recentchangesdiff: Correct broken template that resulted in duplicate
-     diff icons being displayed, and bloated the recentchanges page with
-     inline diffs when the configuration should have not allowed them."""]]
\ No newline at end of file
diff --git a/doc/news/version_3.20130504.mdwn b/doc/news/version_3.20130504.mdwn
new file mode 100644 (file)
index 0000000..18baf01
--- /dev/null
@@ -0,0 +1,11 @@
+ikiwiki 3.20130504 released with [[!toggle text="these changes"]]
+[[!toggleable text="""
+   * Allow dots in directive parameter names. (tango)
+   * Add missing plugin section, and deal with missing sections with a warning.
+   * Detect plugins with a broken getsetup and warn.
+   * map: Correct reversion introduced in version 3.20110225 that could
+     generate invalid html. (smcv)
+   * Makefile.PL: overwrite theme style.css instead of appending
+     (Thanks, Mikko Rapeli)
+   * meta: Fix anchors used to link to the page's license and copyright.
+     Closes: #[706437](http://bugs.debian.org/706437)"""]]
\ No newline at end of file
diff --git a/doc/news/version_3.20130518.mdwn b/doc/news/version_3.20130518.mdwn
new file mode 100644 (file)
index 0000000..635b869
--- /dev/null
@@ -0,0 +1,9 @@
+ikiwiki 3.20130518 released with [[!toggle text="these changes"]]
+[[!toggleable text="""
+   * Fix test suite to not fail when XML::Twig is not installed.
+     Closes: #[707436](http://bugs.debian.org/707436)
+   * theme: Now &lt;TMPL\_IF THEME\_$NAME&gt; can be used in all templates when
+     a theme is enabled.
+   * notifyemail: Fix bug that caused duplicate emails to be sent when
+     site was rebuilt.
+   * bzr: bzr rm no longer has a --force option, remove"""]]
\ No newline at end of file
diff --git a/doc/plugins/contrib/livefyre.mdwn b/doc/plugins/contrib/livefyre.mdwn
new file mode 100644 (file)
index 0000000..d4a62c0
--- /dev/null
@@ -0,0 +1,14 @@
+[[!template id=plugin name=livefyre core=0 author="[[cmauch]]"]]
+[[!tag  type/special-purpose]]
+
+[LiveFyre](http://www.livefyre.com) is a third party comment and discussion system similar in some ways to Disqus or IntenseDebate.  All three services use javascript to attach comments to your site without the need to use a native commenting system.  
+
+This plugin is designed to replace the commenting system in IkiWiki entirely.  It embeds LiveFyre comments on your ikiwiki blog or posts.  It is was originally based on the [Disqus Plugin](https://code.google.com/p/ikiwiki-plugin-disqus/).  After a few days of noticing odd page title names on the livefyre moderation interface, I updated the script to make use of JSON.  I made extensive use of the [integration guide](https://github.com/Livefyre/livefyre-docs/wiki/StreamHub-Integration-Guide) to get it all running.
+
+It's loud and messy and slow, but kind of neat too.
+
+Requires the [[!cpan JSON]], [[!cpan JSON::WebToken]], and [[!cpan Digest::MD5]] perl modules to be available. 
+
+You can grab the source [here](https://bitbucket.org/cmauch/ikiwiki/src/master/IkiWiki/Plugin/livefyre.pm)
+
+See the POD documention in the module for installation and configuration instructions.
diff --git a/doc/plugins/contrib/mathjax.mdwn b/doc/plugins/contrib/mathjax.mdwn
new file mode 100644 (file)
index 0000000..a784b95
--- /dev/null
@@ -0,0 +1,13 @@
+[[!template id="plugin" name="mathjax" author="Baldur Kristinsson"]]
+
+The [mathjax plugin](https://github.com/bk/ikiwiki-plugin-mathjax), available on GitHub, provides easy MathJax support for ikiwiki.
+
+Features:
+
+- No change needed to page.tmpl
+- Javascript is only loaded on pages which need it.
+- Both inline and display math are supported.
+- Unlike [[the pandoc plugin|plugins/contrib/pandoc]] or a solution based on editing page.tmpl, no irritating conflicts with the smiley plugin.
+- Unlike the pandoc plugin, it is easy to use in shared hosting or other environments where you have difficulty in installing extra software (beyond Perl modules, obviously).
+
+However, if you need the power of Pandoc, such as bibliography support or pdf generation, then that is probably the better option for you.
index 5066d9de54be523707f91aaa8f7ca8ee34eb876e..c288d9bd182a59a18818cfef06368f60531267b0 100644 (file)
@@ -3,3 +3,7 @@ Anyone know a safe place where this plugin can be found? -- mjr at phonecoop.coo
 > I ended up doing a backassward way of doing it, as described at the [convert discussion page](http://ikiwiki.info/tips/convert_mediawiki_to_ikiwiki/discussion/). -[[simonraven]]
 
 >> I've mirrored it at <http://alcopop.org/~jon/mediawiki.pm>. -- [[Jon]]
+
+---
+
+Something that gives me better results is to edit the source of the [[wikitext]] plugin, and change all occurences of Text::WikiFormat to Text::MediawikiFormat. (This of course depends on ''libtext-mediawikiformat-perl'' instead of ''libtext-wikiformat-perl'' -- [[gi1242]]
index dc53adf2955d6916663691d79f4b0a62e09794a5..7f8f5faaf1a6fd98117a42196f040d49703c3553 100644 (file)
@@ -1,6 +1,6 @@
 [[!template id=plugin name=proxies author="[[schmonz]]"]]
 [[!template id=gitbranch branch=schmonz/proxies author="[[schmonz]]"]]
-[[!tag type/format]]
+[[!tag type/web]]
 
 This plugin enables ikiwiki to open outbound connections (such as
 found in [[plugins/aggregate]], [[plugins/openid]], and [[plugins/pinger]])
index 400a5bccad9b143822ab3d52368eb09308600ff3..6a1f2d12c64653682965b4466b90174501575cbd 100644 (file)
@@ -1,2 +1,4 @@
 These plugins add different authentication methods for logging in to the
 wiki and control what pages users can edit.
+
+[[!map pages="plugins/* and tagged(.)"]]
index 0bf049ece72d6c40a9b699c1a1d993851a34ec21..980dbbe5776053b50f38ca2df5cec957777e45e8 100644 (file)
@@ -1 +1,3 @@
 These plugins enable whole bundles of other plugins.
+
+[[!map pages="plugins/* and tagged(.)"]]
index a1c6d07283c66623e2c533b349c5375f47cdae20..73a6e58985b80d6ede15b96c3678952608a0d6cf 100644 (file)
@@ -1 +1,3 @@
 These plugins affect the look and feel of the overall wiki.
+
+[[!map pages="plugins/* and tagged(.)"]]
index 6eaa2c25a0b875598549dd27c6c6883e11037fb0..1e4dd7278fc2c42bbb011bde399cebfdc48f0c30 100644 (file)
@@ -1 +1,3 @@
 These plugins relate to [[plugins/comments]].
+
+[[!map pages="plugins/* and tagged(.)"]]
index 71d93c4a6763dea439fd19230504d6079876c73d..2646996ba2fc744adb0f76ead8a86ed063349e8c 100644 (file)
@@ -1 +1,3 @@
 These plugins provide core functionality and are enabled by default.
+
+[[!map pages="plugins/* and tagged(.)"]]
index eae1226dad02b4df9c999b55188717eb42fa314f..b95a7ecd3c05668aec9d323ef65bb3503c298d91 100644 (file)
@@ -1 +1,3 @@
 These plugins control how ikiwiki displays dates.
+
+[[!map pages="plugins/* and tagged(.)"]]
index a60d725d8d1696d832f576ad5c8638912dba3e75..8a100f963a387dcaecd6b6b32c40ee65f6b74b60 100644 (file)
@@ -1 +1,3 @@
 These plugins provide ways to format text on wiki pages.
+
+[[!map pages="plugins/* and tagged(.)"]]
index 4d97c8e6641aa6adac4aec3ea2e7dde3d67cd2a1..ad9e9c2e66c89463fe005b77f6d08a6225eef151 100644 (file)
@@ -1 +1,3 @@
 These plugins are just for fun.
+
+[[!map pages="plugins/* and tagged(.)"]]
index 290208f92312906a0eac02fb463111d7ed2fd89c..94e13b621e6150d0ec6a30dd8a026b73decdd893 100644 (file)
@@ -1 +1,3 @@
 These plugins generate or process html.
+
+[[!map pages="plugins/* and tagged(.)"]]
index c10863fac250d39c4271b3729c73d31b7c304ec1..fce27ae9c6f0c0a0f9a9c065f3d99b9828cb1e8f 100644 (file)
@@ -1 +1,3 @@
 These plugins deal with [[WikiLinks|ikiwiki/WikiLink]].
+
+[[!map pages="plugins/* and tagged(.)"]]
index cae30cad17512e0926c1790a53a4268c66c8f9a1..7a339747e93b89b98f7fddbb1dea2cf8e60f6170 100644 (file)
@@ -1 +1,3 @@
 These plugins deal in meta-information about the wiki.
+
+[[!map pages="plugins/* and tagged(.)"]]
index c0e72158527356b5979ec60f23243b50261cd28c..5907d26f96f75e423392c03080eaac3bb9a37565 100644 (file)
@@ -1,3 +1,5 @@
 These plugins can cause wiki rendering to be significantly slowed down,
 due to things like needing to run an external program for every page
 rendered.
+
+[[!map pages="plugins/* and tagged(.)"]]
index b6ed045313cb89acc1f0df6f2eaae39f84bc36ae..7aeb8be9ce6d71567e900943b88369b101b8508b 100644 (file)
@@ -1 +1,3 @@
 Special-purpose plugins.
+
+[[!map pages="plugins/* and tagged(.)"]]
index bb74066f8f2f0300f4bed9d1f8c8b36bffec807f..78daebd53180781fcd057b93c80c9ce35dcb0a1a 100644 (file)
@@ -1 +1,3 @@
 These plugins support tagging.
+
+[[!map pages="plugins/* and tagged(.)"]]
index b60e26a29f5d6f8246012442f88a5613747ddee5..6ebd6cd373930588e6819ea7e3fd691d0b977e78 100644 (file)
@@ -1 +1,3 @@
 These plugins enhance the web interface.
+
+[[!map pages="plugins/* and tagged(.)"]]
index 875829d0bcdb048f0e0b749f8b8c728ff402e010..496b7da2465d3a94fb93ae36857eb3d1d2532918 100644 (file)
@@ -1,2 +1,4 @@
 These plugins allow inserting various things into pages via a
 [[ikiwiki/directive]].
+
+[[!map pages="plugins/* and tagged(.)"]]
index c7c91e4fbef56d27a3a932960de1fd31c73ecc62..3ecd588439bca77d499ed24269638712615b3db5 100644 (file)
@@ -13,6 +13,10 @@ hello world
 >>> to three levels
 >
 > Back to the first level.
+>
+> added a line in level 1
+> and another
+
 
 Numbered list 
 
@@ -69,6 +73,7 @@ test _this_ out.
 
 _italic_
 
+test ms
 
 opopopo
 ----
index 424d438167dd9ee5272ec55971f261515a4d95ff..b52c72b6b694913394c77fad256b6b93d565ff5f 100644 (file)
@@ -323,6 +323,7 @@ div.progress-done {
 .popup .paren,
 .popup .expand {
        display: none;
+       text-align: left;
 }
 .popup:hover .balloon,
 .popup:focus .balloon {
diff --git a/doc/test.mdwn b/doc/test.mdwn
deleted file mode 100644 (file)
index 8ae0569..0000000
+++ /dev/null
@@ -1 +0,0 @@
-# Test
index 06526df1a2e3dc6ff7c33e343585a3dd4a282f0e..e9bdaa0566e3457a4bcf82742cbcf88710fd5108 100644 (file)
@@ -9,3 +9,5 @@ Feel free to add your own [[theme|themes]] here, but first consider writing a si
  * **[[AntPortal theme|https://github.com/AntPortal/ikiwiked]]**, contributed by Danny, see an example [[on the Antportal wiki|https://antportal.com/wiki/]]
 
  * **[[Night city theme|http://anarcat.ath.cx/night_city/README/]]**, contributed by [[anarcat]], see an example [[on his homepage|http://anarcat.ath.cx/]]
+
+ * **[[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/]]
index 7df25e66b6528f64a342ffc59c3f718e17dcc91d..e15248360cc6a157f8c60045c8a52b4577d232f2 100644 (file)
@@ -3,7 +3,9 @@ ikiwiki a nice look and feel. The local.css [[CSS]] file is left
 free for you to further customize.
 
 Ikiwiki now comes with several themes contributed by users.
-You can enable the [[theme_plugin|plugins/theme]] to use any of these:
+You can enable the [[theme_plugin|plugins/theme]] to use any of
+these, but you can also deploy custom themes maintained by the
+community from the [[theme market]].
 
 [[!img actiontabs_small.png align=left]] The **actiontabs** theme, contributed by
 [[svend]]. This style sheet displays the action list
index ce79d0f70202ec52184bd061f0352c5f0e2be7e9..d01b7838a87d50f3ba97d617fc07250dad63ff6b 100644 (file)
@@ -7,3 +7,8 @@ For an example of the theme in action, see: [[https://antportal.com/wiki/]]
 > Shouldn't we just make people post their themes in the [[themes]] page? Or maybe we should make a [[theme market]]? --[[anarcat]]
 
 > I did just that. -- [[anarcat]]
+
+What is the process for merging a theme in Ikiwiki? It seems to me the
+[[Bootstrap theme|http://www2.tblein.eu/posts/How_to_have_a_nice_design_for_ikiwiki/]]
+could improve the options a lot... See the [[theme market]] for the
+links to the actual theme. -- [[anarcat]]
index 070638e3e41a947f5717f92f26365459cd673bb9..338bca78239e33500f38bf0209150b941796eb63 100644 (file)
@@ -176,6 +176,7 @@ Then you'll have to add a few variables to your path [referenced by your compile
 
     export C_INCLUDE_PATH=YOUR_INSTALL_PATH_HERE/include/
     export LIBRARY_PATH=YOUR_INSTALL_PATH_HERE/lib/
+    export LD_LIBRARY_PATH=YOUR_INSTALL_PATH_HERE/lib/
 
 Then you should be able to install the module, and it'll be faster.
 
index dc88d9595ae838a31d2f00ec9e233e07949631f7..9067fbea57c6f3e77cdb2b72d00403a12d096f2c 100644 (file)
@@ -15,7 +15,10 @@ configuration changes should work anywhere.
 
 ## apache 2
 
-* Edit /etc/apache2/apache2.conf and add a line like this:
+* Make sure the cgi module is loaded. (Ie, `a2enmod cgi`)
+
+* Edit /etc/apache2/apache2.conf (or /etc/apache2/mods-available/mime.conf)
+  and add a line like this:
 
        AddHandler cgi-script .cgi
 
@@ -26,8 +29,6 @@ configuration changes should work anywhere.
   Or, if you've put it in a `~/public_html`, edit
   `/etc/apache2/mods-available/userdir.conf`.
 
-  You may also want to install some dependencies to enable CGI in apache2 setup as: `libcgi-formbuilder-perl` and `libcgi-session-perl`.
-
 * If your wiki is in `~/public_html` and does not appear when you enter the URL given by the installer, check that you have 
   the userdir mod enabled (there should be simlinks to userdir.load and userdir.conf in /etc/apache2/modes-enabled).  If not,
   run `a2enmod userdir` and reload apache2.
index 0c0527f2ce8e84a7d4aff0e1f9a85fb875ad64f5..a59d4b5ad48595418d915b12382370f82a3b3064 100644 (file)
@@ -1,9 +1,244 @@
 [[!meta title="ikiwiki-wordpress-import"]]
 
+I converted the script to Perl.  The new version gets your name and email automatically from your git config, converts the body of your posts to markdown, and also imports comments.  More importantly it works with the latest wordpress, which the python version does not.  Note that it's still not 100% perfect and I intend to make a few modifications still, but they will require access to the mysql database and that may render the script useless to some users.
+
+-----
+[[!format perl '''
+#!/usr/bin/env perl
+
+use 5.16.1;
+use warnings;
+
+use XML::Simple;
+use DateTime::Format::Strptime;
+use HTML::WikiConverter;
+use LWP::UserAgent;
+use Try::Tiny;
+use Digest::MD5 'md5_hex';
+
+die "usage: $0 import_file subdir [branch] | git-fast-import"
+   unless @ARGV == 2 or @ARGV == 3;
+
+chomp(my $name = qx(git config --get user.name));
+chomp(my $email = qx(git config --get user.email));
+
+my ($file, $subdir, $branch) = @ARGV;
+
+my %events;
+
+POST:
+for my $x (grep $_->{'wp:status'} eq 'publish', @{XMLin($file)->{channel}{item}}) {
+   state $date_parser = DateTime::Format::Strptime->new(
+      pattern => '%F %T',
+      time_zone => 'UTC',
+   );
+
+   my $stub = $x =~ m<([^/]+)\/$>
+      ? $1
+      : lc($x->{title} =~ s/\W/-/gr =~ s/-$//r)
+   ;
+
+   my $guid = $x->{guid}{content} || $x->{link};
+   utf8::encode($x->{title});
+   my $msg = qq($x->{title}\n\nfrom WordPress [$guid]);
+   my $timestamp = $date_parser
+      ->parse_datetime($x->{'wp:post_date_gmt'})
+      ->epoch;
+
+   my $c = $x->{category};
+   $c = [$c] if ref $c && ref $c ne 'ARRAY';
+
+   my $content =
+      sprintf(qq([[!meta title="%s"]]\n), $x->{title} =~ s/"/\\"/gr) .
+      convert_content($x->{'content:encoded'}) . "\n\n" .
+      join("\n",
+         map '[[!tag ' . s/ /-/r . ']]',
+         keys %{
+            +{
+               map { $_ => 1 }
+               grep $_ ne 'uncategorized',
+               map $_->{nicename},
+               @$c
+            }
+         }
+      );
+
+   $events{$timestamp} = join "\n",
+      "commit refs/heads/$branch",
+      "committer $name <$email> $timestamp +0000",
+      'data <<8675309',
+      $msg,
+      '8675309',
+      "M 644 inline $subdir/$stub.mdwn",
+      'data <<8675309',
+      $content,
+      '8675309'
+   ;
+
+   get_comments($x->{link}, "$subdir/$stub")
+      if $x->{'wp:post_type'} eq 'post'
+}
+
+sub get_comments {
+   my ($url, $dir) = @_;
+
+   state $ua = LWP::UserAgent->new;
+
+   my $content = $ua->get("$url/feed")->decoded_content;
+   my $first;
+   my $bail;
+   my $decoded =
+      try { XMLin($content, ForceArray => ['item']) }
+      catch { $bail = 1 };
+
+   return if $bail;
+
+   COMMENT:
+   for my $x (@{$decoded->{channel}{item}}) {
+      my $date = $x->{pubDate};
+      $date =~ s/^\S+\s//;
+      $date =~ s/\s\S+$//;
+
+      #ghetto
+      $date =~ s/Jan/01/;
+      $date =~ s/Feb/02/;
+      $date =~ s/Mar/03/;
+      $date =~ s/Apr/04/;
+      $date =~ s/May/05/;
+      $date =~ s/Jun/06/;
+      $date =~ s/Jul/07/;
+      $date =~ s/Aug/08/;
+      $date =~ s/Sep/09/;
+      $date =~ s/Oct/10/;
+      $date =~ s/Nov/11/;
+      $date =~ s/Dec/12/;
+
+      state $date_parser = DateTime::Format::Strptime->new(
+         pattern => '%d %m %Y %T',
+         time_zone => 'UTC',
+      );
+
+      my $datetime = $date_parser
+         ->parse_datetime($date);
+
+      my $timestamp = $datetime->epoch;
+      my $formatted_date = "$timestamp";
+
+      my $msg = 'Added a comment';
+      my $content = convert_content($x->{'content:encoded'});
+      utf8::encode($x->{'dc:creator'});
+
+      $events{$timestamp} = join "\n",
+         "commit refs/heads/$branch",
+         # still need to get email address
+         "committer $x->{'dc:creator'} <$x->{'dc:creator'}> $timestamp +0000",
+         'data <<8675309',
+         $msg,
+         '8675309',
+         "M 644 inline " . unique_comment_location($dir, $content),
+         'data <<8675309',
+
+      <<"COMMENT",
+[[!comment format=mdwn
+ username="$x->{'dc:creator'}"
+ date="$formatted_date"
+ content="""
+$content
+"""]]
+COMMENT
+      '8675309'
+      ;
+   }
+}
+
+say $events{$_} for sort keys %events;
+
+sub convert_content {
+   my $body = shift;
+
+   utf8::encode($body);
+
+   state $converter = HTML::WikiConverter->new(
+      dialect              => 'Markdown',
+      link_style           => 'inline',
+      unordered_list_style => 'dash',
+      image_style          => 'inline',
+      image_tag_fallback   => 0,
+   );
+
+   # I know I know you can't parse XML with regular expressions.  Go find a real
+   # parser and send me a patch
+   my $in_code = 0;
+
+   my $start_code = qr(<pre[^>]*>);
+   # (?:) is a no op but keeps ikiwiki from breaking my script
+   my $end_code = qr(</p(?:)re>);
+
+   $body =~ s(&#(?:8217|039);)(')g;
+   $body =~ s(&(?:quot|#822[01]);)(")g;
+   $body =~ s(&lt;)(<)g;
+   $body =~ s(&gt;)(>)g;
+   $body =~ s(&amp;)(&)g;
+   $body =~ s(&#8230;)(...)g;
+   $body =~ s(&#821[12];)(-)g;
+   $body =~ s(&#8216;)(')g;
+   $body =~ s(&#8242;)(')g;
+   $body =~ s(&infin;)(∞)g;
+   $body =~ s(&nbsp;)()g;
+   $body =~ s(<code[^>]*>)(<p(?:)re>)g;
+   $body =~ s(</c(?:)ode>)(</p(?:)re>)g;
+
+   my @tokens =
+      map {; split qr[(?=<p(?:)re>)] }
+      map {; split qr[</p(?:)re>\K] }
+      split /\n\n/,
+      $body;
+
+   my @new_tokens;
+   for my $t (@tokens) {
+      if (
+         ($in_code && $t !~ $end_code) ||
+         ($t =~ $start_code && $t =~ $end_code)
+      ) {
+         # do nothing
+      } elsif ($t =~ $start_code) {
+         $in_code = 1;
+      } elsif ($t =~ $end_code) {
+         $in_code = 0;
+      } else {
+         die "$t !!! '$1'" if $t =~ m/&([^;\s]+);/ && $1 !~ /[lg]t/;
+
+         $t = "<p>$t</p>"
+      }
+      push @new_tokens, $t
+   }
+
+   $converter->html2wiki(join "\n\n", @new_tokens)
+}
+
+sub unique_comment_location {
+   my ($dir, $content) = @_;
+
+   utf8::encode($content);
+   my $md5 = md5_hex($content);
+
+   my $location;
+   my $i = 0;
+   do {
+      $i++;
+      $location = "$dir/comment_${i}_$md5._comment";
+   } while -e $location;
+
+   return $location
+}
+
+''']]
+-----
+
 I modified the script a bit so categories and tags would actually show up in the output file.
 
 -----
-<pre>
+[[!format '''
 #!/usr/bin/env python
 
 """
@@ -110,7 +345,7 @@ if __name__ == "__main__":
     else:
         main(*sys.argv[1:])
 
-</pre>
+''']]
 -----
 
 I have another version of the script, which uses the `timestamp` from the script, and inserts that as a \[[!meta date="foodate"]]. I'm posting it here just in case I happen to be doing something to the httpd.
@@ -118,7 +353,7 @@ I have another version of the script, which uses the `timestamp` from the script
 (Hopefully I've escaped everything properly; if I missed something, check the source.)
 
 -----
-<pre>
+[[!format '''
 #!/usr/bin/env python
 
 """
@@ -223,7 +458,7 @@ if __name__ == "__main__":
     else:
         main(*sys.argv[1:])
 
-</pre>
+''']]
 -----
 
 
diff --git a/doc/tips/mailman_subscription_form.mdwn b/doc/tips/mailman_subscription_form.mdwn
new file mode 100644 (file)
index 0000000..3e9ed07
--- /dev/null
@@ -0,0 +1,10 @@
+One can think about implementing "[[Mailman integration]]" or something, but I find that rather overdoing it. Mailman is simple enough that you can add a clean subscription form to your ikiwiki site in seconds, just add:
+
+~~~~
+<form action="https://listes.example.com/cgi-bin/mailman/subscribe/listname" method="POST">
+Email: <input name="email" />
+<input type="submit" value="Subscribe" />
+</form>
+~~~~
+
+To your site and voilà, you are done! No more scary mailman subscription form! (Thanks to [[bgm]] for that trick!) --[[anarcat]]
index b504698c495131cef5f594a4e60ad0ede279ccc2..6355867099fc133ad8e884ff09573432142818bc 100644 (file)
@@ -4,7 +4,7 @@ This seems somewhat difficult, as ikiwiki would need to maintain a cache of the
 
 --[[JoshTriplett]]
 
-[scmbug](http://www.mkgnu.net/?q=scmbug) might help here. --[[JoshTriplett]]
+[scmbug](http://www.mkgnu.net/scmbug) might help here. --[[JoshTriplett]]
 
 [[!tag soc]]
 
index 94a4f1577c5f70b3ff1351f0e0e3368635c31b5a..ba01790b3b87f3b76d922289ec33e9091780352e 100644 (file)
@@ -90,3 +90,5 @@ Regards,
      }
      .popup:hover .balloon,
      .popup:focus .balloon {
+
+> [[applied|done]] --[[Joey]]
diff --git a/doc/todo/Fenced_code_blocks___40__from_GitHub_Flavored_Markdown__41__.mdwn b/doc/todo/Fenced_code_blocks___40__from_GitHub_Flavored_Markdown__41__.mdwn
new file mode 100644 (file)
index 0000000..24552b2
--- /dev/null
@@ -0,0 +1,44 @@
+GitHub's flavor of markdown adds fenced code blocks, delimited by triple-backquotes, like this:
+
+    ```
+    code
+    more code
+    ```
+
+That syntax proves quite a bit more convenient in many cases, because it doesn't require modifying every line of the code block to add indentation.  Please consider adding optional support for this in ikiwiki.  Please also consider turning it on by default for new wikis, though not for existing wikis since it could *potentially* break backward compatibility with existing content.
+
+> I don't think that's an official markdown feature, although it might be available
+> as an extension in some markdown library or other -- possibly one of the ones
+> supported by ikiwiki.
+> 
+> However, aside from compatability, ikiwiki already provides a way to do it that does not
+> require indenting the code: The [[ikiwiki/directive/format]] directive. Which has the benefit of
+> also telling it what kind of code it is, so it can syntax highlight it. Example:
+
+[[!format haskell """
+main :: IO ()
+main = forever $
+  putStrLn "hello, world!"
+"""]]
+
+> --[[Joey]]
+
+> > It is not a standard feature (as much as Markdown is [[standardized|Track_Markdown_Standardisation_Efforts]]...) But it does allow for [syntax hilightning](https://help.github.com/articles/github-flavored-markdown) too, just tag the language name after the backticks. It *seems* that Discount supports github-style backtick format (as well as Pandoc `~~~~` format) but doesn't allow the keyword argument.
+> > 
+> > I strongly support this feature. --[[anarcat]]
+> > 
+> > In fact, it turns out that it already works here!
+> >
+> > ~~~~
+> > this is a pandoc-style fenced in code block
+> > this is another line
+> > ~~~~
+> > 
+> > github-style backticks, however, do not add a wrapping `<pre>` block for some reason:
+> >
+> > ```
+> > this is a github-style fenced in code block
+> > this is another line
+> > ```
+> >
+> > ... maybe a bug in Discount... --[[anarcat]]
index cfae38465d184a6d76f051400f95e6e52f86651b..9aee29037eaa9994fae96ee2977d55496dc4aa2f 100644 (file)
@@ -95,3 +95,5 @@ index 285013e..151e839 100644
 </pre>
 
 [[!tag patch]]
+
+> [[done]] --[[Joey]]
index a4940220adef0fabdbc10175f27c5bfe5e198df9..b7ff82282ed04078907ef889a14538004c6b6cd5 100644 (file)
@@ -13,6 +13,8 @@ A slightly more complex next step would be to request sreg from the provider and
 > implemented as a badly-done wart on the side of their regular login
 > system.
 > 
+> > If there are user profiles on the site with non-empty information associated with them (including permissions, reputation), then it would make more sense to be able to access your user profile with alternative OpenIDs (in case one of the provider goes down), as on <http://stackoverflow.com>. In ikiwiki, there might be no such special information associated with users (or you can think of something like this?), except for the admin rights. But fortunately, several OpenIDs can be set up for admins in ikwiki. (Only if it comes to [the OpenIDs provided by Gmail][forum/google openid broken?], then it turns out to be unhandy to write the ID into the configuration file as a second admin ID.)--Ivan Z.
+> 
 > The openid plugin now attempts to get an email and a username, and stores
 > them in the session database for later use (ie, when the user edits a
 > page).
index a0405472b64110f0e6ee210d4b92384964a105ce..63ffccf0d8d41abf24df21adf78d0a3463af74bd 100644 (file)
@@ -13,4 +13,8 @@ The installed bin/ikiwiki file also refers to /usr/bin/perl rather than the perl
 > yours, but do not plan to work on it myself, since I do not use systems
 > where /usr/bin/perl is not a sane default. --[[Joey]]
 
+> > I've implemented a change that should fix this.  For what it's worth this is a
+> > life saver on shared hosting where building your own perl is super effective.
+> > --frioux ([code here](https://github.com/frioux/ikiwiki/tree/use-env-perl))
+
 [[wishlist]]
diff --git a/doc/todo/calendar_with___34__create__34___links.mdwn b/doc/todo/calendar_with___34__create__34___links.mdwn
new file mode 100644 (file)
index 0000000..9fe6c43
--- /dev/null
@@ -0,0 +1,10 @@
+the [[ikiwiki/directive/calendar]] directive is well usable without ikiwiki-calendar (eg for articles about meetings), but in such situations, it might be useful to have page creating links at the days.
+
+a [[!taglink patch]] to address this [[!taglink wishlist]] item is [[attached|incomplete_patch.pl]].
+
+from the new documentation (also in the patch):
+
+> * `newpageformat` - In month mode, if no articles match the query, the value of
+>   `newpageformat` will be used to strformat the date in question. A good value
+>   is `newpageformat="meetings/%Y-%m-%d"`. It might be a good idea to have
+>   `\[[!meta date="<TMPL_VAR name>"]]` in the edittemplate of `meetings/*`
diff --git a/doc/todo/calendar_with___34__create__34___links/incomplete_patch.pl b/doc/todo/calendar_with___34__create__34___links/incomplete_patch.pl
new file mode 100644 (file)
index 0000000..dc67988
--- /dev/null
@@ -0,0 +1,36 @@
+diff --git a/IkiWiki/Plugin/calendar.pm b/IkiWiki/Plugin/calendar.pm
+index d443198..0436eda 100644
+--- a/IkiWiki/Plugin/calendar.pm
++++ b/IkiWiki/Plugin/calendar.pm
+@@ -238,7 +238,16 @@ EOF
+                       else {
+                               $tag='month-calendar-day-nolink';
+                       }
+-                      $calendar.=qq{\t\t<td class="$tag $downame{$wday}">$day</td>\n};
++                      if ($params{newpageformat}) {
++                              $calendar.=qq{\t\t<td class="$tag $downame{$wday}">};
++                              $calendar.=htmllink($params{page}, $params{destpage},
++                                      strftime_utf8($params{newpageformat}, 0, 0, 0, $day, $params{month} - 1, $params{year} - 1900),
++                                      noimageinline => 1,
++                                      linktext => $day);
++                              $calendar.=qq{</td>\n};
++                      } else {
++                              $calendar.=qq{\t\t<td class="$tag $downame{$wday}">$day</td>\n};
++                      }
+               }
+       }
+diff --git a/doc/ikiwiki/directive/calendar.mdwn b/doc/ikiwiki/directive/calendar.mdwn
+index cb40f88..7b7fa85 100644
+--- a/doc/ikiwiki/directive/calendar.mdwn
++++ b/doc/ikiwiki/directive/calendar.mdwn
+@@ -56,5 +56,9 @@ An example crontab:
+   and so on. Defaults to 0, which is Sunday.
+ * `months_per_row` - In the year calendar, number of months to place in
+   each row. Defaults to 3.
++* `newpageformat` - In month mode, if no articles match the query, the value of
++  `newpageformat` will be used to strformat the date in question. A good value
++  is `newpageformat="meetings/%Y-%m-%d"`. It might be a good idea to have
++  `\[[!meta date="<TMPL_VAR name>"]]` in the edittemplate of `meetings/*`.
+ [[!meta robots="noindex, follow"]]
index 8ce3dd3e7cace45eb7dc8573099c4dddd22ac67b..4b534ee67ef1983bbd178528cf42734e4e04b817 100644 (file)
@@ -5,6 +5,38 @@ also have lots more metadata.
 
 [[!toc]]
 
+## Status
+
+[[!template id=gitbranch branch=schmonz/fancypodcast author="[[schmonz]]"]]
+[[!tag patch]]
+
+In summary, the branch preserves ikiwiki's existing podcast behavior,
+adds more featureful behavior, and has been tested to work well in
+some common podcatchers. I believe it is ready for review and
+possible integration, and I'd like to get feedback to that effect
+(or to the contrary) before making further enhancements. I know
+[[joey]]'s the final arbiter here, but I'd appreciate any qualified,
+critical eyes ([[smcv]]?) raking over my diffs. --[[schmonz]]
+
+## Features
+
+[[!table data="""
+Feature            |iTunes RSS|iTunes Atom|Downcast RSS|Downcast Atom
+Feed image         |          |           |            |
+Feed title         |(./)      |(./)       |(./)        |(./)
+Feed publisher     |          |           |            |
+Feed "category"    |          |           |            |
+Feed date          |(./)      |(./)       |(./)        |(./)
+Feed description   |(./)      |(./)       |(./)        |
+Episode image      |          |           |            |
+Episode title      |(./)      |(./)       |(./)        |(./)
+Episode date       |(./)      |(./)       |(./)        |(./)
+Episode duration   |          |           |            |
+Episode author     |          |           |            |
+Episode description|(./)      |(./)       |(./)        |
+Episode enclosure  |(./)      |(./)       |(./)        |(./)
+"""]]
+
 ## Design
 
 7. For each fancy podcast episode, write a blog post containing
@@ -18,9 +50,6 @@ also have lots more metadata.
 
 ## Implementation
 
-[[!template id=gitbranch branch=schmonz/fancypodcast author="[[schmonz]]"]]
-[[!tag patch]]
-
 ### Completed
 
 * Cover the existing simple podcast behavior with tests.
@@ -42,34 +71,113 @@ also have lots more metadata.
 * Verify that the feeds validate.
 * Subscribe to a fancy feed in some common podcatchers and verify
   display details against a reference podcast.
-
-### Status
-
-[[!table data="""
-Feature            |iTunes RSS|iTunes Atom|Downcast RSS|Downcast Atom
-Feed image         |{X}       |{X}        |{X}         |{X}
-Feed title         |(./)      |(./)       |(./)        |(./)
-Feed publisher     |{X}       |{X}        |{X}         |{X}
-Feed "category"    |{X}       |{X}        |{X}         |{X}
-Feed date          |(./)      |(./)       |(./)        |(./)
-Feed description   |(./)      |(./)       |(./)        |{X}
-Episode image      |{X}       |{X}        |{X}         |{X}
-Episode title      |(./)      |(./)       |(./)        |(./)
-Episode date       |(./)      |(./)       |(./)        |(./)
-Episode duration   |{X}       |{X}        |{X}         |{X}
-Episode author     |{X}       |{X}        |{X}         |{X}
-Episode description|(./)      |(./)       |(./)        |{X}
-Episode enclosure  |(./)      |(./)       |(./)        |(./)
-"""]]
+* Verify smooth transitions for two common use cases (see testing
+  details below).
 
 ### Must-have (for [[schmonz]], anyway)
 
-* Think carefully about...
-    * UTF-8.
-    * Whether [[tips/howto avoid flooding aggregators]] suffices for
-      migrating a fancy podcast into ikiwiki.
+* Think carefully about UTF-8.
 * Verify that _all_ the tests pass (not just my new ones).
 
+## Migration
+
+### Upgrading within ikiwiki: from simple to fancy
+
+#### My test podcast
+
+For this test, I chose a podcast that tries to work around ikiwiki's
+current limitations by issuing two separate `inline`s:
+
+* One with `feedonly=yes` that includes `.mdwn`, `.pdf`, and `.mp3`
+* One with `feeds=no` that includes only `.mdwn` (and makes a trail)
+
+This has the following effects:
+
+* Browser: sees just the articles (each of which has a manually
+  created link to its corresponding media file)
+* Feedreader: sees all the articles and media in one flat stream
+* Podcatcher: sees just the media (sans articles)
+
+I want instead to write one `inline` with these effects:
+
+* Browser: sees just the articles (each of which automatically links
+  to its enclosure)
+* Feedreader: sees just the articles (each of which specifies its
+  enclosure)
+* Podcatcher: sees just the enclosures (each of which has an enclosing
+  article, rendered as the media's "description")
+
+#### Upgrade steps
+
+7. Set up a non-production copy of the podcast.
+    7. Visually diff RSS and Atom feeds against production.
+    7. Subscribe to the copy (both feeds) in `r2e`, iTunes, Downcast.
+7. Apply fancypodcast patch to the installed ikiwiki:
+    7. `cd ~/Documents/trees/ikiwiki && git checkout fancypodcast`
+    7. `git diff --no-prefix master > ~/Documents/trees/localpatches/www/ikiwiki/fancypodcast.diff`
+    7. `cd ~/Documents/trees/pkgsrc-current/www/ikiwiki && make deinstall && make install clean`
+7. Verify that simple podcasts are unaffected:
+    7. Rerun `ikiwiki --setup`.
+    7. `diff -uB simple-before.rss simple-after.rss`
+        * A few new elements and attributes, as expected.
+    7. `diff -uB simple-before.atom simple-after.atom`
+        * No change.
+7. Remove the feed-only `inline` and enable feeds on the remaining one.
+7. Convert articles' manual download links to `\[[!meta enclosure=""]]`.
+7. I want existing and future podcatchers to get my new fancy
+   episodes, and I know my podcast isn't in any planets, so I'm
+   going to skip [[tips/howto avoid flooding aggregators]].
+7. Rerun `ikiwiki --setup`.
+7. Verify browser shows the same stuff.
+7. `diff -uB simple-after.rss fancy-after.rss   # and atom`
+    * MP3s and PDFs are no longer naked enclosures, but belong to
+      articles as they should.
+    * Articles have updated modification times, as they should.
+7. `r2e run` (both RSS and Atom)
+    * Nothing new with the default `trust-guid = True` (otherwise
+      would expect updated articles).
+7. iTunes "Update Podcast" (both RSS and Atom)
+    * Added one episode per article, with article text as the episode
+      description.
+    * Kept old naked-enclosure episodes around.
+7. Downcast refresh (RSS):
+    * Added one episode per article, with article text as the episode
+      description.
+    * Kept old naked-enclosure episodes around.
+7. Downcast refresh (Atom):
+    * Added one episode per article, with no episode description
+      (expected, see feature table).
+    * Kept old naked-enclosure episodes around.
+
+Different tradeoffs are possible. These seem okay to me.
+
+### Importing into ikiwiki: fancy (from another CMS)
+
+#### My test podcast
+
+For this test, I chose a podcast currently being published with
+Textpattern and tru_podcast, because I'd strongly prefer to publish
+it with ikiwiki instead.
+
+#### Upgrade steps
+
+7. Set up a non-production copy of the podcast.
+    7. Visually diff RSS and Atom feeds against production.
+    7. Subscribe to the copy (both feeds) in `r2e`, iTunes, Downcast.
+7. With a fancypodcast-enabled ikiwiki installed:
+    7. Copy content from Textpattern to ikiwiki:
+        7. Match article paths to preserve `/YYYY/MM/DD/post-title` permalinks.
+        7. Match enclosure paths (or redirect) to preserve Textpattern's URLs.
+        7. Match titles, post dates, and guids with `\[[!meta]]`.
+           7. Match feed paths with permanent redirects from `/atom/` to
+           `/index.atom` (and same for RSS).
+        7. `\[[!inline]]` the articles.
+    7. Rerun `ikiwiki --setup`.
+7. Stop Textpattern, start ikiwiki.
+7. Verify that podcatchers see the feeds and don't redownload anything.
+7. Naively add two new blog posts, one with an enclosure.
+7. Verify that podcatchers download the new enclosures.
+
 -----
 
 ## Future improvements
@@ -104,6 +212,8 @@ Episode enclosure  |(./)      |(./)       |(./)        |(./)
 
 ### Other ideas
 
+* Don't render template text (e.g., "Use this template to insert a
+  note into a page") in feeds.
 * Optionally specify the enclosure's:
     * MIME type, in case `File::MimeInfo` guesses wrong.
     * Duration, in case `ffprobe` guesses wrong.
@@ -115,3 +225,44 @@ Episode enclosure  |(./)      |(./)       |(./)        |(./)
 * Configurably generate additional subscription links (such as
   iTunes) alongside the RSS/Atom ones in [[plugins/inline]].
 * Support Apple's "enhanced podcasts" (if they're still relevant).
+
+### code review
+
+       +                               # XXX better way to compute relative to srcdir?
+       +                               my $file = $absurl;
+       +                               $file =~ s|^$config{url}/||;
+
+I don't think ikiwiki offers a better way to do that, because there is
+normally no reason to do that. Why does it need an url of this form here?
+--[[Joey]] 
+
+       +<TMPL_IF HTML5><section id="inlineenclosure"><TMPL_ELSE><div id="inlineenclosure"></TMPL_IF>
+       +<TMPL_IF ENCLOSURE>
+
+Can't we avoid adding this div when there's no enclosure? --[[Joey]]
+
+       +<a href="<TMPL_VAR ENCLOSURE>">Download this episode</a>
+
+"Download this episode" is pretty specific to particular use cases.
+Can this be made more generic, perhaps just "Download"? --[[Joey]] 
+
+       -<TMPL_IF AUTHOR>
+       -       <title><TMPL_VAR AUTHOR ESCAPE=HTML>: <TMPL_VAR TITLE></title>
+       -       <dcterms:creator><TMPL_VAR AUTHOR ESCAPE=HTML></dcterms:creator>
+
+This change removes the athor name from the title of the rss feed, which
+does not seem necessary for fancy podcasts. And it is a change that
+could negatively impact eg, Planet style aggregators using ikiwiki. --[[Joey]]
+
+       +++ b/templates/rsspage.tmpl
+       +       xmlns:atom="http://www.w3.org/2005/Atom"
+       +<atom:link href="<TMPL_VAR FEEDURL>" rel="self" type="application/rss+xml" />
+
+Why is it using atom namespace inside an rss feed? What are the chances
+every crummy rss reader on earth is going to understand this? I'd put it at
+about 0%; I doubt ikiwiki's own rss reader understands such a mashup.
+--[[Joey]]
+
+       +<generator>ikiwiki</generator>
+
+Does this added tag provide any benefits? --[[Joey]]
diff --git a/doc/todo/toc-with-human-readable-anchors.mdwn b/doc/todo/toc-with-human-readable-anchors.mdwn
new file mode 100644 (file)
index 0000000..0f358f4
--- /dev/null
@@ -0,0 +1,7 @@
+The [[/plugins/toc]] plugin is very useful but it creates anchors with names such as #index1h3
+
+In #ikiwiki today, another user and I were in agreement that an option for human readable anchors would be preferable.
+
+> +1 - i would love to see that happen too. Here's a patch I wrote a while back for similar functionality in moinmoin: https://svn.koumbit.net/koumbit/trunk/patches/moinmoin/nice_headings.patch -- [[anarcat]]
+
+[[!tag wishlist]]
diff --git a/doc/todo/translation_links.mdwn b/doc/todo/translation_links.mdwn
new file mode 100644 (file)
index 0000000..63e8d10
--- /dev/null
@@ -0,0 +1,46 @@
+This is an offshoot of [[this rant|translation/discussion/#index3h1]].
+
+Basically, while I can appreciate the [[plugins/po]] plugin for more or less "static" site, or more organised wikis, for certain wikis, it's way too overhead.
+
+## Stories
+
+The following stories should be answered by that plugin:
+
+ 1. a user browses the wiki, finds that the page is translated in another language and clicks on the language to see that page translated
+ 2. a user browses the wiki and gets automatically the right language
+ 3. an editor creates a wiki page, and it gets assigned a language
+ 4. a translator sees that page and translates it to another language, and that page is linked with the first one, both ways (in that stories 1 and 2 can work)
+ 5. (optional) a translator can see the list of pages needing translation and translate pages
+ 6. (optional) an editor changes a wiki page, the translated page is marked as "dirty" (ie. needing translation)
+
+## Fundamental constraints
+
+This issue is about creating a "wikipedia-like" translation structure where:
+
+ 1. there's no "master language"
+ 2. there's a loose connexion between pages
+ 3. not all pages are necessarily translated, nor is it a goal
+
+Those are fundamental constraints that should be required by that plugin. It doesn't mean that the plugin cannot be used otherwise, but that's all it needs to respect to fulfill the requirements here.
+
+## Optional constraints
+
+There can be more constraints that we may want to impose or not, which will make things more or less complicated:
+
+ 4. the page URLs need to be translatable - it would make [[!wikipedia Content_negotiation]] fail, so it would require the CGI for story 2. it would also make it harder to create the connexion between pages, as metadata would be needed in each page
+ 5. the language must not be visible in the URL - same as #4
+ 6. translation system must also be usable from the commandline/git repository - #5 and #6 would be basically impossible to implement there
+
+## Basic spec
+
+ 1. a hook that looks for foo.la.mdwn pages, where la is a language code (defined where..?), and that lists available translations - 
+    this is where most of the work needs to happen. we can probably reuse the builtin template stuff that got injected with the [[plugins/po]] plugin was imported, to start with
+ 2. instructions on how to setup [[!wikipedia Content_negotiation]] so that the above works out of the box - just documentation
+ 3. a button to create such translations - that would be through the [[pageactions hook|plugins/write/#index15h3]]
+ 4. a default language setting? - that's obviously the getsetup hook
+ 5. a set of language code settings? - same
+ 6. content-negotiation - the po module has good code for that
+
+## Authors
+
+ * [[anarcat]]
index 61606e3d0d067f4daf5fbf7db09cbf7cf12ec73d..b274317cd34dc17d93a1b8b834fabb98aa99e642 100644 (file)
@@ -117,3 +117,5 @@ Obviously, this is a lot more work, diverging in a different direction than the
 Also, the thing with the above is that if functionalities 1 and 2 (mapping and page flipping) is stripped out of the po plugin and made reusable, functionalities 3 and 4 can be made optional and a wiki is still translatable, giving the user the responsability of tracking the translations...
 
 So basically, what I think should happen is to have ikiwiki be able to use the .po plugin without .po files - just allow for pages to be linked together. Detect foo.fr.mdwn when parsing foo.mdwn and create links to it would already be a huge start... -- [[anarcat]]
+
+> I have a hopefully clearer spec for a plugin called [[todo/translation_links]]. -- [[anarcat]]
index 10ca6e6ebe1cbb1bf16ab25fe44ede99be302f99..97fa1cbd66c11de7b5062f8cb78592249a09e0f4 100644 (file)
@@ -1,10 +1,32 @@
-[Amitai Schlair](http://www.schmonz.com/) finds himself using ikiwiki
-for all sorts of things. His attempts at contributing:
+[Amitai Schlair](http://www.schmonz.com/) has contributed code to ikiwiki...
 
 [[!map
 pages="!*/Discussion and ((link(users/schmonz) and plugins/*) or rcs/cvs or todo/fancypodcast)"
 ]]
 
-He's also written a plugin for [WIND
-authentication](http://www.columbia.edu/acis/rad/authmethods/wind/), which
-may or may not be of general utility.
+...and uses ikiwiki for all sorts of things:
+
+## Public
+
+* [A major open-source project's wiki](http://wiki.netbsd.org) (with
+  the [[rcs/cvs]] plugin)
+* [An undergraduate group's university-provided-static-hosted
+  site](http://www.columbia.edu/cu/philo/) (with [[plugins/rsync]] and a [WIND
+  authentication](http://www.columbia.edu/acis/rad/authmethods/wind/) plugin)
+* [A small personal site](http://www.anglofish.net/) (happily hosted at
+  [Branchable](http://www.branchable.com/))
+
+## Non-public
+
+* At work, team documentation and project planning: product and sprint
+  backlogs, burndown charts, release plans/procedures/announcements,
+  aggregating feeds of shared interest, etc. (with the
+  [[plugins/contrib/dynamiccookies]] and [[plugins/contrib/proxies]] plugins)
+* On my laptop, personal to-do and scratch space
+* [A small personal site](http://podcast.schmonz.com/) (happily hosted at
+  [Branchable](http://www.branchable.com/))
+
+## Non-yet-ikiwiki
+
+* [My personal web site](http://www.schmonz.com/) (pending
+  [[todo/fancypodcast]] integration)
diff --git a/doc/wishlist/watched_pages.mdwn b/doc/wishlist/watched_pages.mdwn
new file mode 100644 (file)
index 0000000..d943571
--- /dev/null
@@ -0,0 +1 @@
+Is there a way to mark pages I edit as "watched"? A way of doing this through git would be acceptable too. Right now I link to my homepage on every page I comment on, but this doesn't tell me if the pages were updated... --[[anarcat]]
index 7caaca7178dfbb1cc65defe74976742581d41384..9d799da3fc0a7ebd014ddb5e42fd00808231d45a 100644 (file)
@@ -1,5 +1,5 @@
 Name:           ikiwiki
-Version: 3.20130212
+Version: 3.20130518
 Release:        1%{?dist}
 Summary:        A wiki compiler
 
index 8d739f95bbbc014e4eb82b7b28d15334d2efe0b3..3f2fac90b57d68b594c7e3f695d7d6c6661de7e7 100644 (file)
@@ -8,7 +8,7 @@ msgid ""
 msgstr ""
 "Project-Id-Version: PACKAGE VERSION\n"
 "Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2013-02-12 21:50-0400\n"
+"POT-Creation-Date: 2013-05-18 16:34-0400\n"
 "PO-Revision-Date: YEAR-MO-DA HO:MI+ZONE\n"
 "Last-Translator: FULL NAME <EMAIL@ADDRESS>\n"
 "Language-Team: LANGUAGE <LL@li.org>\n"
@@ -561,11 +561,11 @@ msgstr ""
 msgid "Cannot subscribe your email address without logging in."
 msgstr ""
 
-#: ../IkiWiki/Plugin/notifyemail.pm:135
+#: ../IkiWiki/Plugin/notifyemail.pm:136
 msgid "change notification:"
 msgstr ""
 
-#: ../IkiWiki/Plugin/notifyemail.pm:137
+#: ../IkiWiki/Plugin/notifyemail.pm:138
 msgid "comment notification:"
 msgstr ""
 
diff --git a/t/map.t b/t/map.t
index 7f3df61f7c9068f8ea28aeac6d929f685530ba4a..5d4713d6fc9604d91018280c253911082d75c212 100755 (executable)
--- a/t/map.t
+++ b/t/map.t
@@ -3,9 +3,16 @@ package IkiWiki;
 
 use warnings;
 use strict;
-use XML::Twig;
 use Test::More;
 
+BEGIN {
+        unless (eval { require XML::Twig }) {
+                eval q{
+                        use Test::More skip_all => "XML::Twig is not available"
+                }
+        }
+}
+
 BEGIN { use_ok("IkiWiki"); }
 BEGIN { use_ok("IkiWiki::Render"); }
 BEGIN { use_ok("IkiWiki::Plugin::map"); }