Commit Graph

2092 Commits (2d9e97c283cb7b1ecdd524e60bddec17ee638835)

Author SHA1 Message Date
Joey Hess 2d9e97c283 chdir to the destdir before running rsync
Avoids needing to specify the path in the rsync command, can just use "."
2009-09-11 18:19:21 -04:00
Joey Hess dcc177440e remove unixauth; I am only adding render at the moment
yeah, you need branches :P
2009-09-11 18:15:19 -04:00
Amitai Schlair a69d628b2c Whoops, copyright 2009. /usr/bin/perl for the interpreter like other plugins. 2009-09-11 14:13:47 -04:00
Amitai Schlair b2bd2e93f0 Revivify unixauth and rsync plugins (and hook needed by rsync) lost in
the last merge. I should really put each feature on its own git branch.
2009-09-10 17:34:52 -04:00
Joey Hess 9ef4b5e677 Merge commit 'schmonz/master' 2009-09-10 17:04:20 -04:00
Amitai Schlair fb6c6895c6 Add NetBSD-style 2-clause BSD license. 2009-09-10 17:03:06 -04:00
Joey Hess e3f5fdcf37 remove hook not used by cvs 2009-09-10 16:28:39 -04:00
Joey Hess 60111384a9 formatting 2009-09-10 16:21:03 -04:00
Joey Hess 73224daf2c minor simplification 2009-09-10 16:20:21 -04:00
Joey Hess 1365ebf12f Merge commit 'schmonz/master' into cvs 2009-09-10 16:18:27 -04:00
Joey Hess 93cd30bc0a Merge branch 'master' into cvs 2009-09-10 16:18:23 -04:00
Joey Hess 26dae8f049 clean up use of IkiWiki::Receive
Loading and use of IkiWiki::Receive can all be pushed into the git plugin,
rather than scattered around.

I had at first wanted to make a receive plugin and move it there,
but a plugin was not a good fit; you don't want users to have to manually
load it, and making the git plugin load the receive plugin at the right
times would need more, and ugly code.
2009-09-10 16:15:48 -04:00
Amitai Schlair 8063bc3402 Catch up to the new genwrapper hook. 2009-09-10 15:12:45 -04:00
Amitai Schlair 460b1a0deb Merge branch 'master' of git://github.com/joeyh/ikiwiki 2009-09-10 15:03:18 -04:00
Joey Hess 3ebd4e0b45 Add genwrapper hook, that can be used to add code into the C wrapper. 2009-09-10 14:04:46 -04:00
Joey Hess f5bd1cf3cd typo 2009-09-10 13:49:42 -04:00
Joey Hess c22b938631 Merge commit 'schmonz/master' into cvs 2009-09-10 13:44:31 -04:00
Joey Hess 81a9b5feff Merge branch 'master' into cvs 2009-09-10 13:44:27 -04:00
Amitai Schlair 98553d1537 CVS operations generally need to be within CVS checkouts, so these chdir()
calls are warranted. They shouldn't modify the caller's working directory,
though. Use File::chdir to keep the scope of the changes subroutine-local.
The tests now pass without resetting the working directory.
2009-09-10 00:51:34 -04:00
Amitai Schlair aafd267ee0 Abstract out CVS's involvement in the wrapper:
* In Wrapper.pm, add a new hook "wrapperargcheck" to examine argc/argv
  and return success or failure. In the failure case, the wrapper
  terminates.

* In cvs.pm, implement the new hook to return failure if a directory is
  being cvs added.
2009-09-09 21:58:42 -04:00
Amitai Schlair 5f44dd8e77 Merge branch 'master' of git://github.com/joeyh/ikiwiki 2009-09-09 14:44:52 -04:00
Joey Hess 2a99ebf276 underlay: Also allow configuring additional directories to search for template files in. 2009-09-08 17:27:37 -04:00
Joey Hess 55474f44d9 Expand banned_users; it can now include PageSpecs, which allows banning by IP address. 2009-09-08 15:17:39 -04:00
Joey Hess 8c55424b11 Merge commit 'schmonz/master' into cvs
Conflicts:
	IkiWiki/Plugin/cvs.pm
2009-09-04 17:16:28 -04:00
Amitai Schlair d79cf3728d It's STDOUT we have to shut up for cvs, and $savedout has to be
restored just so.
2009-09-04 14:56:55 -05:00
Amitai Schlair 9de742bb00 Stop using IPC::Cmd and String::ShellQuote, since quoting (and
having to quote, and the possible use of the shell) sucks. Stop
passing args to cvs_runcvs() as an arrayref, since that also sucks
(and was a sop to IPC::Cmd). Instead, use Joey's construction for
temporarily redirecting stderr to /dev/null. Much much simpler and
better. Works on my laptop with bozohttpd, now to test on the NetBSD
wiki.
2009-09-04 12:40:04 -05:00
Joey Hess de7c3aa16b minor formatting 2009-09-02 16:08:18 -04:00
Joey Hess 9f5cc7c9a2 remove two plugins that are unrelated to cvs 2009-09-02 15:36:56 -04:00
Amitai Schlair 85844b8494 whitespace 2009-08-30 21:03:18 -04:00
Amitai Schlair fe350e8b89 Merge branch 'master' of git://github.com/joeyh/ikiwiki 2009-08-30 16:34:32 -04:00
Amitai Schlair 1af7d7d842 On some systems the commit message gets quoted properly already. Don't
requote in such cases, do quote in all others.
2009-08-30 16:13:17 -04:00
Joey Hess d678147410 Revert "po: do not inject custom bestlink function when po_link_to eq default"
This reverts commit cdc3576c8d.

Conflicts:

	IkiWiki/Plugin/po.pm

This change broke the test suite and is not strictly necessary.
2009-08-30 14:50:43 -04:00
Amitai Schlair e972cadf78 Fix uninitialized value when editing a page being vivified from the
basewiki. Makes the filetype-testing logic more explicit anyway.
2009-08-30 13:49:38 -04:00
Amitai Schlair c36d2fa896 Merge branch 'master' of git://github.com/joeyh/ikiwiki 2009-08-30 03:02:15 -04:00
Amitai Schlair 5e94e973ee Only examine argv if the VCS is cvs. 2009-08-30 02:00:49 -04:00
Amitai Schlair 968c6c93b4 Remove debug statement. 2009-08-30 01:45:09 -04:00
Amitai Schlair 2d1ff30e13 Knock off another to-do item: "Don't slurp the entire cvsps output
into memory (!)."
2009-08-30 01:14:22 -04:00
Amitai Schlair b493f9b6d8 Knock off a to-do item: "If the argument to cvs add smells like a
binary file, cvs add -kb it (for attachment support)."
2009-08-30 00:17:42 -04:00
Amitai Schlair 992d0aac09 The string to match might not be "New directory" exactly, so match that
substring instead.
2009-08-30 00:05:23 -04:00
Amitai Schlair 6191f3fbb9 Remove getopt() hook (it's a dead end, unsafe to pass wrapper args to
ikiwiki). Crunch on-demand module loads into one-liners. Comment why
cvsps output is getting read in its entirety and reversed.
2009-08-29 21:35:54 -04:00
Josh Triplett 9f75d3b1f3 teximg: Make TeX handle preventing unsafe things; remove insufficient blacklist
TeX has configuration options that prevent unsafe things like shell
escapes and insecure file reads/writes.  Turn all of them on.

teximg's regex-based blacklist does not suffice.  For instance:

[[!teximg code="""
\catcode`\%=0
%input{/etc/passwd}
"""]]

Remove the blacklist, since the TeX configuration options seal off the
underlying mechanisms more safely, and the blacklist blocks other TeX
commands that can prove useful.
2009-08-28 23:18:07 -07:00
Joey Hess 03449610d6 img: Don't generate new verison of image if it is scaled to be larger in either dimension.
Although imagemagick handles even really large sizes sanely, using a page
file, doing so would just waste time and disk space, since the browser
can be told to resize it larger.
2009-08-28 23:31:53 -04:00
Joey Hess 3811c5f559 Merge commit 'intrigeri/po' 2009-08-28 19:48:32 -04:00
Joey Hess ec26a96193 avoid clobbering origsub if checkconfig runs more than once
checkconfig can run more than once in a single ikiwiki run if setup is
building wrappers. That clobbered the origsub value for bestlink, leading
to infinite recursion
2009-08-28 19:15:25 -04:00
Joey Hess 125c6ec650 <pedant>rename depends_exact to depends_simple
It's not "exact" since case munging has to be done, and I think
"simple" captures the optimisation better.</pedant>

With apologies to smcv, who probably has to rebuild his wiki now.
2009-08-28 15:13:45 -04:00
Simon McVittie 20a38fbf6d Avoid duplicating debug message for building a page due to a dependency
As per Joey's review
2009-08-28 15:42:07 +01:00
Simon McVittie 2a7f3b91d4 Force %depends_exact to lower case, fixing incorrect case-sensitivity 2009-08-28 15:42:04 +01:00
intrigeri 646c9a4c95 po: fix link() pagespec when used on translation pages
Signed-off-by: intrigeri <intrigeri@boum.org>
2009-08-28 16:34:58 +02:00
Simon McVittie ec2367cfbf Fix typo in dependency debug message 2009-08-28 15:34:35 +01:00
Simon McVittie c80a3cbcfd Add depends_exact: simplified dependency tracking for dependencies on a single page
Let E be the number of dependencies per page of the form "A depends on B and
nothing else", let D be the number of other dependencies per page,
let P be the total number of pages, and let C be the number of changed
pages in a refresh.

This patch should speed up a refresh from O(E*C*P + D*C*P) to
O(C + E*P + D*C*P), assuming that hash lookups are O(1).

In practice, plugins like inline and map produce a lot of these very simple
dependencies, and my album plugin's combination of inline with a large
number of pages causes it to suffer particularly badly.

In testing on a wiki with about 7000 objects (3500 full pages, 3500
images), a full rebuild continued to take about 5:30, and a refresh
after touching about 350 pages and 350 images reduced from 5:30 to 1:30.

As with my previous optimizations, this change will result in downgrades not
working correctly until the wiki is rebuilt.
2009-08-28 15:34:35 +01:00