[Jifty-commit] r2100 - in wifty/trunk: bin lib/Wifty
jifty-commit at lists.jifty.org
jifty-commit at lists.jifty.org
Tue Oct 31 23:49:39 EST 2006
Author: jesse
Date: Tue Oct 31 23:49:39 2006
New Revision: 2100
Modified:
wifty/trunk/ (props changed)
wifty/trunk/bin/import_kwiki
wifty/trunk/lib/Wifty/Dispatcher.pm
Log:
r29669 at pinglin: jesse | 2006-10-31 23:48:33 -0500
* importer updates for svk wiki conversion
Modified: wifty/trunk/bin/import_kwiki
==============================================================================
--- wifty/trunk/bin/import_kwiki (original)
+++ wifty/trunk/bin/import_kwiki Tue Oct 31 23:49:39 2006
@@ -1,4 +1,4 @@
-#!/usr/bin/perl
+#!/opt/local/bin/perl
use warnings;
use strict;
@@ -8,7 +8,7 @@
use Jifty;
Jifty->new();
-get_pages('/tmp/svkwiki/data/database');
+get_pages(shift @ARGV);
@@ -21,17 +21,17 @@
# chomp(@content);
close $file;
my $content = join("\n", at content);
- return unless $content;
+ return unless length($content) > 4;
my $html = Text::KwikiFormatish::format( $content);
- $name =~ s/\s*//g;
+ #$name =~ s/\s*//g;
$page->load_by_cols(name =>$name);
if ($page->id) {
$page->set_content($content);
}
else {
my ($ret)= $page->create( name => $name, content => $content);
- warn $ret;
+ warn $ret. ": $name";
}
}
Modified: wifty/trunk/lib/Wifty/Dispatcher.pm
==============================================================================
--- wifty/trunk/lib/Wifty/Dispatcher.pm (original)
+++ wifty/trunk/lib/Wifty/Dispatcher.pm Tue Oct 31 23:49:39 2006
@@ -83,7 +83,7 @@
};
# Show recent edits
-on 'recent', run {
+on 'recent*', run {
my $then = DateTime->from_epoch( epoch => ( time - ( 86400 * 7 ) ) );
my $pages = Wifty::Model::PageCollection->new();
$pages->limit(
More information about the Jifty-commit
mailing list