diff options
author | Pascal Rigaux <pixel@mandriva.com> | 2006-11-24 19:13:38 +0000 |
---|---|---|
committer | Pascal Rigaux <pixel@mandriva.com> | 2006-11-24 19:13:38 +0000 |
commit | 829ce242a2656ee2933cc630a1b618769ca0d1b0 (patch) | |
tree | 0190495ccfca8a3a2b49f8dee5810474e1fde776 | |
parent | 298bb002ec4f7b0e9fd1e949a984800295deba4c (diff) | |
download | urpmi-829ce242a2656ee2933cc630a1b618769ca0d1b0.tar urpmi-829ce242a2656ee2933cc630a1b618769ca0d1b0.tar.gz urpmi-829ce242a2656ee2933cc630a1b618769ca0d1b0.tar.bz2 urpmi-829ce242a2656ee2933cc630a1b618769ca0d1b0.tar.xz urpmi-829ce242a2656ee2933cc630a1b618769ca0d1b0.zip |
don't allow --probe-synthesis or --probe-hdlist without --use-distrib for
urpmi/urpmq/urpme
-rw-r--r-- | urpm/args.pm | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/urpm/args.pm b/urpm/args.pm index e890add0..54b95022 100644 --- a/urpm/args.pm +++ b/urpm/args.pm @@ -408,6 +408,10 @@ sub parse_cmdline { $options{$k} = $args{defaults}{$k}; } my $ret = GetOptions(%{$options_spec{$tool}}); + + if ($tool ne 'urpmi.addmedia' && $options{probe_with} && !$options{usedistrib}) { + die N("Can't use %s without %s", "--probe-$options{probe_with}", "--use-distrib"); + } if ($tool eq 'urpmf' && @ARGV && $ARGV[0] eq '--') { if (@ARGV == 2) { my $p = $ARGV[1]; |