[Yum-devel] [PATCH] Make -- work with firstParse, without breaking other options. BZ 694394.

seth vidal skvidal at fedoraproject.org
Thu Apr 7 19:30:39 UTC 2011


On Thu, 2011-04-07 at 15:09 -0400, James Antill wrote:
> ---
>  cli.py |    7 +++++--
>  1 files changed, 5 insertions(+), 2 deletions(-)
> 
> diff --git a/cli.py b/cli.py
> index b0a6292..aefb841 100644
> --- a/cli.py
> +++ b/cli.py
> @@ -1434,8 +1434,7 @@ class YumOptionParser(OptionParser):
>                           '-e', '--errorlevel',
>                           '--installroot',
>                           '--disableplugin', '--enableplugin', '--releasever',
> -                         '--setopt',
> -                         '--'),
> +                         '--setopt'),
>                          args)
>          except ValueError, arg:
>              self.base.usage()
> @@ -1699,6 +1698,7 @@ def _filtercmdline(novalopts, valopts, args):
>  
>      Will raise ValueError if there was a problem parsing the command line.
>      '''
> +    # ' xemacs syntax hack
>      out = []
>      args = list(args)       # Make a copy because this func is destructive
>  
> @@ -1709,6 +1709,9 @@ def _filtercmdline(novalopts, valopts, args):
>              if opt in valopts:
>                  out.append(a)
>  
> +        elif a == '--':
> +            out.append(a)
> +
>          elif a in novalopts:
>              out.append(a)
>  


ACK.

-sv




More information about the Yum-devel mailing list