# 3. Send the installed version to the Repository for checking. # I used to only upgrade from the place it came from. Now it will come # from the current repository. my $res = $pkg->uptodate($target); unless ($res->ok) { return Error("bundled package - no upgrade available") if $bundled; return $res; } my ($uptodate, $newversion) = $res->result_l; # 4. Return uptodate(t/f), newversion, oldversion, bundled(t/f): return List($uptodate, $bundled, $precious, $newversion, $ver_p); } # Find the first repository containing the package, and report whether the # package is up-to-date w.r.t that repository. sub uptodate { my $o = shift; my $target = PPM::UI::get_targ(shift)->result; my $desc = $o->describe($target); if ($o->{current_rep} and $desc and $desc->ok) { my $u2d = $o->{current_rep}->uptodate( $target, $o->{id}, $desc->result->version_osd, ); return $u2d; } Error("package $o->{rawname} not found in repositories"); }