2 package IkiWiki::Plugin::rsync;
9 hook(type => "getsetup", id => "rsync", call => \&getsetup);
10 hook(type => "postrefresh", id => "rsync", call => \&postrefresh);
21 example => "rsync -qa --delete . user\@host:/path/to/docroot/ --exclude ikiwiki.cgi",
22 description => "command to run to sync updated pages",
29 if (defined $config{rsync_command}) {
30 chdir($config{destdir}) || error("chdir: $!");
31 system $config{rsync_command};
33 warn(sprintf(gettext("failed to execute rsync_command: %s"), $!))."\n";
36 warn(sprintf(gettext("rsync_command exited %d"), $? >> 8))."\n";