diff options
Diffstat (limited to 'lib/Iurt/Ulri.pm')
-rwxr-xr-x | lib/Iurt/Ulri.pm | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/lib/Iurt/Ulri.pm b/lib/Iurt/Ulri.pm index 6d4e38f..f2e014c 100755 --- a/lib/Iurt/Ulri.pm +++ b/lib/Iurt/Ulri.pm @@ -12,6 +12,7 @@ use strict; our @EXPORT = qw( build_package + fetch_logs_and_cleanup warn_about_failure ); @@ -144,6 +145,13 @@ sub get_pid_from_file { $pid; } +sub fetch_logs_and_cleanup { + my ($remote, $remote_dir, $target_dir) = @_; + make_path($target_dir); + sget($remote, "$remote_dir/log/*", $target_dir); + ssh($remote, "rm -rf $remote_dir"); +} + sub warn_about_failure { my ($config, $user, $ent, $arch, $fail_dir, $path, $prefix) = @_; my $text = join("\n", "Build of the following packages failed:\n", map { "- $_" } @{$ent->{srpms}}) . "\n"; |