Joey Hess
dfd6bb3854
fix data:image handling
2008-02-10 15:24:03 -05:00
Joey Hess
d7e0c035e5
* htmlscrubber security fix: Block javascript in uris.
...
* Add htmlscrubber test suite.
2008-02-10 13:16:40 -05:00
Joey Hess
a4b2e77077
add support for prefix_directives
2008-02-05 16:14:38 -05:00
Joey Hess
f64ef7deb6
proper fix for the preview/will_render issue
2008-02-04 18:46:34 -05:00
Joey Hess
b37dc9c926
preview shouldn't show the feed buttons or post form
2008-02-04 18:44:54 -05:00
Joey Hess
bf522a347f
* inline: Add new `allowrss` and `allowatom` config options. These can be
...
used if you want a wiki that doesn't default to generating rss or atom
feeds, but that does allow them to be turned on for specific blogs.
2008-02-04 18:36:50 -05:00
Joey Hess
85de2f7bc4
the old code worked, suprisingly, but I prefer this form
2008-02-04 18:05:40 -05:00
Joey Hess
d1c4899a22
* inline: When previewing, still call will_render on rss/atom files,
...
just avoid actually writing the files. This is necessary because ikiwiki
saves state after a preview (in case it actually *did* write files),
and if will_render isn't called its security checks will get upset
when the page is saved. Thanks to Edward Betts for his help tracking this
tricky bug down.
2008-02-04 17:58:23 -05:00
Joey Hess
9d54cc4659
implement aggregate_locking design
...
Now aggregation will not lock the wiki. Any changes made during aggregaton are
merged in with the changed state accumulated while aggregating. A separate
lock file prevents multiple concurrent aggregators. Garbage collection
of orphaned guids is much improved. loadstate() is only called once
per process, so tricky support for reloading wiki state is not needed.
(Tested fairly thuroughly.)
2008-02-03 16:48:26 -05:00
Joey Hess
38affb0c1c
add aggregate locking functions
2008-02-03 15:17:15 -05:00
Joey Hess
e57749b702
* recentchanges: Exipre all *._change pages, even if the directory
...
they're in has changed.
2008-02-03 14:51:03 -05:00
Joey Hess
340fe9707c
* recentchanges: Improve handling of links on the very static changes pages
...
by thunking to the CGI, which can redirect to the page, or allow it to be
created if it doesn't exist.
2008-02-03 14:48:20 -05:00
Joey Hess
42e5b8dfdc
prototype fix
2008-02-03 14:22:25 -05:00
Joey Hess
1f6591f0a6
* aggregate: Revert use of forking to not save state, that was not the right
...
approach.
2008-02-03 03:04:19 -05:00
Joey Hess
9f60272831
* poll: This plugin turns out to have edited pages w/o doing any locking.
...
Oops. Convert it from a cgi to a sessioncgi hook, which will work
much better.
2008-02-03 00:26:00 -05:00
Joey Hess
0779013683
* aggregate: Forking a child broke the one state that mattered: Forcing
...
the aggregating page to be rebuilt. Fix this.
2008-02-02 23:56:13 -05:00
Joey Hess
870adf3bbf
move openiduser function to the openid plugin
2008-01-30 02:39:17 -05:00
Joey Hess
55e16be44a
move recentchanges link enabling into a pagetemplate hook
2008-01-30 02:29:12 -05:00
Joey Hess
f584abec0c
really fix the baseurl problem
...
the issue is that HTML::Template doesn't expand top-level variables when inside
a loop
2008-01-29 18:19:47 -05:00
Joey Hess
3803266b8f
merged the recentchanges branch
...
misc fixes
2008-01-29 17:50:11 -05:00
Joey Hess
7a40bcab9a
add missing test to avoid uninitialised value when a page with metadata is removed
2008-01-29 17:36:25 -05:00
Joey Hess
64a8c828b8
* meta: Add pagespec functions to match against title, author, authorurl,
...
license, and copyright. This can be used to create custom RecentChanges.
* meta: To support the pagespec functions, metadata about pages has to be
retained as pagestate.
* Fix encoding bug when pagestate values contained spaces.
2008-01-29 17:16:51 -05:00
Joey Hess
bc49e284ac
make the author metadata for changes pages be the un-munged openid
2008-01-29 16:05:31 -05:00
Joey Hess
8b31c53366
added configuration for recentchanges
...
I kept it to a simple global configuration, rather than using the
preprocessor directive for recentchanges, because that had chicken and egg
problems and seemed overcomplicated. This should work reasonably well,
though it would be good to add some more metadata so that more customised
recentchanges pages can be made.
2008-01-29 15:51:32 -05:00
Joey Hess
cabd5140c4
add code to delete old change pages
2008-01-29 15:22:23 -05:00
Joey Hess
35bc35660c
use new refresh hook
2008-01-29 13:08:48 -05:00
Joey Hess
a5ad70a8dc
updates
2008-01-29 12:59:49 -05:00
Joey Hess
598d338b11
escape wikilinks and preprocessor directives
2008-01-29 12:37:39 -05:00
Joey Hess
85eb1abc61
typo
2008-01-29 04:45:54 -05:00
Joey Hess
38e79f206e
more style improvements
2008-01-29 04:44:05 -05:00
Joey Hess
21f44880cd
non-tabular recentchanges display
...
Doesn't look as good as the old table, but works as a rss feed.
2008-01-29 01:48:55 -05:00
Joey Hess
d2a3695376
some parameteraisation and generalisation
2008-01-29 01:03:15 -05:00
Joey Hess
5921b86fcc
proof of concept implementation of static recentchanges
...
Currently hardcoded to write to recentchanges/*, and the page format needs
to be rethought to be usable for aggregation, but it basically works.
2008-01-28 23:56:26 -05:00
Joey Hess
2d3dc86d07
* prettydate,ddate: Don't ignore time formats passed to displaytime
...
function.
2008-01-28 23:48:27 -05:00
Joey Hess
3436fed081
* inline: The template can check for FIRST and LAST, which will be
...
set for the first and last inlined page. Useful for templates that build
tables and the like.
2008-01-28 21:22:04 -05:00
Josh Triplett
fafb2edaa7
aggregate.pm: Replace Unicode apostrophe with ASCII to unbreak build
...
gettext choked on a Unicode apostrophe in the aggregate plugin, which
appeared in a new error message in commit
4f872b5633
. Replace it with an ASCII
apostrophe.
2008-01-26 23:12:29 -08:00
Joey Hess
4f872b5633
* aggregate: Fork a child process to handle the aggregation. This simplifies
...
the code, since that process can change internal state as needed, and
it will automatically be cleaned up for the parent process, which proceeds
to render the changes.
2008-01-24 17:22:39 -05:00
Joey Hess
ba6b8e5e3e
* aggregate: Don't let feeds set creation times for pages in the future.
2008-01-16 02:01:00 -05:00
Patrick Winnertz
81c726982b
I've wrote a little patch for the bug in teximg (can only include fomula on
...
one page).
2008-01-09 20:04:51 -05:00
Joey Hess
e01960e90a
not only markdown adds gunk, so remove it in the main htmlize function
2008-01-09 14:41:28 -05:00
Joey Hess
2b9ce0129b
* mdwn: When htmlizing text, if it's a single line with no newline,
...
remove the enclosing paragraph and newline markdown wraps it in.
This allows removing several hacks around this markdown behavior from
other plugins that htmlize fragements of pages.
2008-01-09 14:35:23 -05:00
Joey Hess
57ff2ecaed
* template: Remove bogus htmlize pass added in 2.16.
...
* template: Htmlize template variables, but also provide a raw version
via `<TMPL_VAR raw_variable>`.
2008-01-09 14:17:25 -05:00
Joey Hess
adb1bc8761
don't process data metadata in scan, as it's expensive and the metadata should not be needed so early
2008-01-09 02:41:38 -05:00
Joey Hess
deb39a1f14
* meta: Run in scan mode again (more intelligently) and re-add support for
...
meta link.
* Fix support for the case where metadata appears after an inline directive.
This was broken in version 2.16.
2008-01-09 02:38:43 -05:00
Joey Hess
a654a72fda
optimisation: detect scan mode and avoid generating image
2008-01-09 02:31:11 -05:00
Joey Hess
b31e8c0826
* inline: Add copyright/license info on a per-post basis to atom
...
feeds if available. (rss doesn't allow such info on a per-post basis)
* meta: Allow copyright/license metadata to contain arbitrary markup.
2008-01-09 01:05:54 -05:00
Joey Hess
86781fc43e
* aggregate: Include copyright statements from rss feed as meta copyright
...
directives.
* aggregate: Yet another state saving fix (sigh).
* aggregate: Add hack to support feeds with invalidly escaped html entities.
2008-01-08 20:41:25 -05:00
Joey Hess
4c1a4402f9
* htmlscrubber: Further work around #365971 by adding tags for 'br/', 'hr/'
...
and 'p/'.
2008-01-07 18:32:50 -05:00
Joey Hess
d7b2bb13d1
fixes
2008-01-07 16:37:19 -05:00
Joey Hess
c487b847e2
* Improved the canedit hook interface, allowing a callback function to be
...
returned (and not run in some cases) rather than the plugins directly
forcing a user to log in.
* opendiscussion: allow editing of the toplevel discussion page,
and, indirectly, allow creating new discussion pages.
2008-01-07 16:34:13 -05:00
Joey Hess
45de8dc710
* opendiscussion: allow editing of the toplevel discussion page
2008-01-07 16:10:32 -05:00
Joey Hess
4ac5685744
fix some bad copy and pasted plugin ids
2008-01-07 15:28:53 -05:00
Joey Hess
ceffae8af1
* aggregate: Only save state if it was already loaded. This didn't used to
...
* table: Fix dependency tracking for external data files. Closes : #458387
2008-01-05 02:23:31 -05:00
Joey Hess
76e941a480
* aggregate: Only save state if it was already loaded.
2008-01-05 01:26:09 -05:00
Joey Hess
41234a3f0f
round days old message
2008-01-02 23:38:45 -05:00
Joey Hess
c3eec7fdf0
I *think* that this comment is out of date.
2007-12-30 14:57:33 -05:00
Joey Hess
f0f52e602d
* aggregate: Fix stupid mistake introduced when converting it to use
...
the needsbuild hook. This resulted in feeds not being removed when pages
were updated, and probably other bugs.
* aggregate: Avoid uninitialised value warning when removing a feed that
has an expired guid.
2007-12-30 14:49:25 -05:00
Joey Hess
3e784ea8a1
* map: Fix handling of common prefix to handle the case where it's
...
in a subdirectory. Patch by Larry Clapp.
2007-12-28 17:22:17 -05:00
Joey Hess
63f62ef520
* conditional: Improve regexp testing for simple uses of pagespecs
...
that match only the page using the directive, adding 'included()'
and supporting negated pagespecs and added whitespace.
2007-12-28 16:55:20 -05:00
Joey Hess
c2afda7f90
* img: Allow the link parameter to point to an exterior url.
2007-12-28 16:14:43 -05:00
Joey Hess
2332b40595
* img: Avoid nesting images when linking to another image. Closes : #457780
2007-12-26 10:49:15 -05:00
Thomas Schwinge
1ac0fd03bb
IkiWiki/Plugin/meta.pm <redir>: Support for specifying anchors.
2007-12-22 13:10:55 -05:00
Joey Hess
b72b8b2b0e
improve error message if shortcuts.mdwn DNE
2007-12-17 15:33:47 -05:00
Joey Hess
f373b09bf9
loadstate needs to be called even if no pages are being built
2007-12-16 19:40:50 -05:00
Joey Hess
c3fed25ad4
* brokenlinks: Don't list the same link multiple times. (%links might
...
contain multiple copies of the same link)
2007-12-16 16:42:18 -05:00
Joey Hess
1d60cb322d
correct variable scoping error in nils's patch
2007-12-16 16:07:52 -05:00
Nis Martensen
723a10b5b1
rssurl and atomurl are only needed where $feeds is set
2007-12-16 16:04:38 -05:00
Nis Martensen
c99369cdbe
Also increment feednum only if feeds are generated
2007-12-16 16:04:28 -05:00
Joey Hess
9459cc55ab
* meta: Drop support for "meta link", since supporting this for internal
...
* map: Don't inline images.
2007-12-16 16:00:13 -05:00
Joey Hess
96817b0032
* meta: Drop support for "meta link", since supporting this for internal
...
links required meta to be run during scan, which complicated its data
storage, since it had to clear data stored during the scan pass to avoid
duplicating it during the normal preprocessing pass.
* If you used "meta link", you should switch to either "meta openid" (for
openid delegations), or tags (for internal, invisible links). I assume
that nobody really used "meta link" for external, non-openid links, since
the htmlscrubber ate those. (Tell me differently and I'll consider bringing
back that support.)
* meta: Improved data storage.
* meta: Drop the hackish filter hook that was used to clear
stored data before preprocessing, this hack was ugly, and broken (cf:
liw's disappearing openids).
* aggregate: Convert filter hook to a needsbuild hook.
2007-12-16 15:56:09 -05:00
Nis Martensen
74a56db8d6
Set page_numfeeds only if feeds are being generated
2007-12-12 16:54:09 -05:00
Joey Hess
10a2895b3b
* shortcut: Expand %S to the raw input text, not url-encoded.
2007-12-12 16:50:29 -05:00
Joey Hess
7eafa95f33
* Htmlize parameters passed to the template preprocessor directive before
...
inserting them into the html template. This ensures that markdown
acts on them, even if the value is expanded inside a block-level html
element in the html template. Closes : #454058
* Use a div in the note template rather than a span.
2007-12-12 16:42:54 -05:00
Joey Hess
3922ba15ba
don't duplicate code from editpage, just pull the values it sets out of the
...
formbuilder object
2007-12-12 03:35:23 -05:00
Joey Hess
4745391360
* Change formbuilder hook to not be responsible for displaying a form,
...
so that more than one plugin can use this hook.
I believe this is a safe change, since only passwordauth uses this hook.
(If some other plugin already used it, it would have broken passwordauth!)
2007-12-12 03:15:30 -05:00
Joey Hess
c46b17983d
works, but I'm not entirely happy with it yet
...
It would be better if it were a formbuilder hook. But the formbuilder hook
is wacked.. I may need to change how that hook works, which would mean
changing the only current user of it, passwordauth).
2007-12-12 02:45:44 -05:00
Joey Hess
8576fe4c49
incomplate edittemplate plugin
2007-12-12 01:52:26 -05:00
Joey Hess
c8cb931890
reorg
2007-12-09 00:05:07 -05:00
Joey Hess
e78c25d1b2
logic fix
2007-12-08 23:57:25 -05:00
Joey Hess
5023f2301d
* The calendar plugin stores state about when it needs to be updated,
...
and forces rebuilds of the pages that contain calendars. So
running ikiwiki --refresh at midnight is now enough, no need for a full
wiki rebuild each midnight.
* calendar: Work around block html parsing bug in markdown 1.0.1 by
enclosing the calendar in an extra div.
2007-12-08 23:54:34 -05:00
Joey Hess
5959a32f97
real redir cycle detection
2007-12-08 19:39:32 -05:00
Joey Hess
a829e5b865
ensure state is dropped when a page stops embeddeding the version
2007-12-08 19:12:50 -05:00
Joey Hess
b4b452f4ee
forgot to add
2007-12-08 19:05:01 -05:00
Joey Hess
055179cb4c
* Finally implemented a simple per-page data storage mechanism for plugins,
...
via the %pagestate hash.
* Use pagestate in meta to detect potential redir loops.
2007-12-08 17:40:50 -05:00
Joey Hess
7960031135
MAJOR basewiki reorg
...
Including redir pages for the moved basewiki pages. These will be removed in
a future release.
2007-12-08 15:59:08 -05:00
Joey Hess
b8681e19d1
wikilink fix
2007-12-08 15:17:37 -05:00
Joey Hess
ccf99970a7
drop redir loop detection code
...
it won't work for incremental builds
for now, relying on browsers to notice loops
2007-12-08 15:05:41 -05:00
Joey Hess
2c78477387
* meta: Add redir support, based on a patch by Thomas Schwinge.
2007-12-08 14:58:29 -05:00
Thomas Schwinge
655d7925c6
Here is a patch to add a forwarding functionality to the meta plugin
2007-12-08 14:37:41 -05:00
Joey Hess
c3805557f1
* Improve workaround for perl bug #376329 . Rather than double-encoding,
...
which has been reported to cause encoding problems (though I haven't
reproduced them), just catch a failure of markdown, and retry.
(The crazy perl bug magically disappears on the retry.)
Closes : #449379
2007-11-27 16:36:37 -05:00
Joey Hess
c9c0f271b6
* toc: Handle html elements embedded inside a header, rather than
...
stopping collecting the header text at the first element.
2007-11-23 11:40:02 -05:00
Joey Hess
e016a975c4
* Allow html5 video and audio tags and their attributes in the htmlscrubber.
2007-11-18 13:34:06 -05:00
Joey Hess
6ccd9313d2
* More compact output for the brokenlinks plugin.
2007-11-17 16:16:34 -05:00
Joey Hess
ebac523686
prottype fixes
2007-11-14 08:51:38 -05:00
Joey Hess
264a82a435
* inline: Add timeformat parameter to control how the ctime of
...
inlined pages is displayed. Closes : #451019
2007-11-13 16:14:48 -05:00
Joey Hess
6a751b2a83
missed localising a string
2007-11-08 15:03:57 -05:00
Josh Triplett
21c6d61aa1
Fix table plugin to not generate an unbalanced tbody tag with header=no
...
The table plugin omitted </tbody> with header=no, but always generated
<tbody>, resulting in an unbalanced tag. Fix that by omitting <tbody>
too.
2007-11-08 11:30:15 -08:00
Joey Hess
930584cff7
* map: Recent changes caused unnecessary ul's to be inserted for items
...
that were all at the same level, fix. Closes : #449285
2007-11-07 16:34:50 -05:00
Joey Hess
1c9946ff48
reset SIGPIPE before returning
2007-11-05 19:33:28 -05:00
Joey Hess
2a6e353c20
improve use of seen hash
2007-10-30 22:56:13 -04:00