$(PERL) -Iblib/lib $(extramodules) $(tflag) ikiwiki.out -libdir . -setup docwiki.setup -refresh
extra_clean:
- rm -rf html doc/.ikiwiki
+ $(PERL) -I. $(extramodules) $(tflag) ikiwiki.in -libdir . -setup docwiki.setup -clean
rm -f *.man ikiwiki.out ikiwiki.setup plugins/*.pyc
$(MAKE) -C po clean
-ikiwiki (3.20100213) UNRELEASED; urgency=low
+ikiwiki (3.20100228) UNRELEASED; urgency=low
* comments: Display number of comments in comment action link.
* Rebuild wikis on upgrade to this version to get the comment counts
files/directories.
* Fix admin openid detection in setup automator, and avoid prompting
for a password.
+ * Add new --clean option; this makes ikiwiki remove all built
+ files in the destdir, as well as wrappers and the .ikiwiki directory.
-- Joey Hess <joeyh@debian.org> Sun, 14 Feb 2010 17:02:10 -0500
If used with --setup --refresh, this makes it also update any configured
wrappers.
+* --clean
+
+ This makes ikiwiki clean up by removing any files it denerated in the
+ `destination` directory, as well as any configured wrappers, and the
+ `.ikiwiki` state directory. This is mostly useful if you're running
+ ikiwiki in a Makefile to build documentation and want a corresponding
+ `clean` target.
+
* --cgi
Enable [[CGI]] mode. In cgi mode ikiwiki runs as a cgi script, and
"syslog!" => \$config{syslog},
"rebuild!" => \$config{rebuild},
"refresh!" => \$config{refresh},
+ "clean!" => \$config{clean},
"post-commit" => \$config{post_commit},
"render=s" => \$config{render},
"wrappers!" => \$config{genwrappers},
if (@{$config{wrappers}} &&
! $config{render} && ! $config{dumpsetup} &&
+ ! $config{clean} &&
((! $config{refresh} && ! $config{post_commit})
|| $config{genwrappers})) {
debug(gettext("generating wrappers.."));
# setup implies a wiki rebuild by default
if (! $config{refresh} && ! $config{render} &&
- ! $config{post_commit}) {
+ ! $config{post_commit} && ! $config{clean}) {
$config{rebuild}=1;
}
}
elsif ($config{post_commit} && ! commit_hook_enabled()) {
# do nothing
}
+ elsif ($config{clean}) {
+ require IkiWiki::Render;
+ foreach my $wrapper (@{$config{wrappers}}) {
+ prune($wrapper->{wrapper});
+ }
+ clean_rendered();
+ system("rm", "-rf", $config{wikistatedir});
+ }
else {
if ($config{rebuild}) {
debug(gettext("rebuilding wiki.."));