summaryrefslogtreecommitdiffstats
path: root/urpmq
diff options
context:
space:
mode:
authorPascal Rigaux <pixel@mandriva.com>2008-01-17 11:57:37 +0000
committerPascal Rigaux <pixel@mandriva.com>2008-01-17 11:57:37 +0000
commit2864278acd38b3b4bd5410c2022d21bf3154e933 (patch)
tree4ad7fed58db7e7d5f2a6e592e4baf4f9436c82ef /urpmq
parentaf7637f44d8b40f1945607f12f1b066a54dc6a8b (diff)
downloadurpmi-2864278acd38b3b4bd5410c2022d21bf3154e933.tar
urpmi-2864278acd38b3b4bd5410c2022d21bf3154e933.tar.gz
urpmi-2864278acd38b3b4bd5410c2022d21bf3154e933.tar.bz2
urpmi-2864278acd38b3b4bd5410c2022d21bf3154e933.tar.xz
urpmi-2864278acd38b3b4bd5410c2022d21bf3154e933.zip
- urpmq:
o add --provides
Diffstat (limited to 'urpmq')
-rwxr-xr-xurpmq11
1 files changed, 11 insertions, 0 deletions
diff --git a/urpmq b/urpmq
index ae9c5db7..e874c055 100755
--- a/urpmq
+++ b/urpmq
@@ -77,6 +77,7 @@ usage:
authentication (format is <user:password>).
") . N(" --env - use specific environment (typically a bug report).
") . N(" --changelog - print changelog.
+") . N(" --provides - print provides.
") . N(" --sourcerpm - print sourcerpm.
") . N(" --summary, -S - print summary.
") . N(" --verbose, -v - verbose mode.
@@ -440,6 +441,16 @@ if ($options{list_aliases}) {
}
}
exit 0;
+ } elsif ($options{provides}) {
+ my @l = uniq_ { scalar $_->fullname } map { $urpm->{depslist}[$_] } map { split /\|/, $_ } keys %{$state->{selected}};
+ foreach my $pkg (@l) {
+ if (@l > 1) {
+ printf "%s: %s\n", $pkg->name, $_ foreach $pkg->provides;
+ } else {
+ print "$_\n" foreach $pkg->provides;
+ }
+ }
+ exit 0;
}
}
$urpmi_lock and $urpmi_lock->unlock;