diff options
Diffstat (limited to 'usr.sbin/pkg_add/OpenBSD/Update.pm')
-rw-r--r-- | usr.sbin/pkg_add/OpenBSD/Update.pm | 16 |
1 files changed, 7 insertions, 9 deletions
diff --git a/usr.sbin/pkg_add/OpenBSD/Update.pm b/usr.sbin/pkg_add/OpenBSD/Update.pm index 261656fa470..757a76a424d 100644 --- a/usr.sbin/pkg_add/OpenBSD/Update.pm +++ b/usr.sbin/pkg_add/OpenBSD/Update.pm @@ -1,5 +1,5 @@ # ex:ts=8 sw=4: -# $OpenBSD: Update.pm,v 1.92 2009/11/11 11:18:24 espie Exp $ +# $OpenBSD: Update.pm,v 1.93 2009/11/11 12:04:19 espie Exp $ # # Copyright (c) 2004-2006 Marc Espie <espie@openbsd.org> # @@ -44,14 +44,12 @@ sub process_handle my ($self, $set, $h, $state) = @_; my $pkgname = $h->pkgname; if (defined $h->{update}) { - $state->progress->clear; - print "Update to $pkgname already found\n"; + $state->say("Update to $pkgname already found"); return 0; } if ($pkgname =~ m/^(?:\.libs\d*|partial)\-/o) { - $state->progress->clear; - print "Not updating $pkgname, remember to clean it\n"; + $state->say("Not updating $pkgname, remember to clean it"); return 0; } my @search = (); @@ -112,8 +110,7 @@ sub process_handle } if (@$l == 1) { if ($state->{defines}->{pkgpath}) { - $state->progress->clear; - print "Directly updating $pkgname -> ", $l->[0]->name, "\n"; + $state->say("Directly updating $pkgname -> ", $l->[0]->name); $self->add_updateset($set, $h, $l->[0]); return 1; } @@ -121,12 +118,13 @@ sub process_handle !$plist->uses_old_libs && !$state->{defines}->{installed}) { my $msg = "No need to update $pkgname"; $state->progress->message($msg); - print "$msg\n" if $state->{beverbose}; + $state->say($msg) if $state->{beverbose}; return 0; } } - $state->print("Candidates for updating $pkgname -> ", join(' ', map {$_->name} @$l), "\n"); + $state->say("Candidates for updating $pkgname -> ", + join(' ', map {$_->name} @$l)); my $r = $state->choose_location($pkgname, $l); if (defined $r) { |