[svk-commit] r2161 - trunk/lib/SVK/Command
clkao at bestpractical.com
clkao at bestpractical.com
Fri Nov 17 22:30:33 EST 2006
Author: clkao
Date: Fri Nov 17 22:30:32 2006
New Revision: 2161
Modified:
trunk/lib/SVK/Command/Sync.pm
Log:
Don't exit with 0 when sync has failures.
Modified: trunk/lib/SVK/Command/Sync.pm
==============================================================================
--- trunk/lib/SVK/Command/Sync.pm (original)
+++ trunk/lib/SVK/Command/Sync.pm Fri Nov 17 22:30:32 2006
@@ -51,6 +51,7 @@
@mirrors = map { $_->mirror->get( $_->path ) } @arg;
}
+ my $error;
for my $m (@mirrors) {
my $run_sync = sub {
$m->sync_snapshot($self->{skip_to}) if $self->{skip_to};
@@ -61,6 +62,7 @@
print loc( "Starting to synchronize %1\n", $m->get_svkpath->depotpath );
eval { $run_sync->() };
if ($@) {
+ ++$error;
warn $@;
last if ( $@ =~ /^Interrupted\.$/m );
}
@@ -70,7 +72,7 @@
$run_sync->();
}
}
- return;
+ return $error ? 1 : 0;
}
1;
More information about the svk-commit
mailing list