1
0
mirror of https://github.com/openSUSE/osc.git synced 2025-02-03 18:16:17 +01:00

cmdln: Order options and arguments by the order of decorators in the source code

This commit is contained in:
Daniel Mach 2022-09-20 09:59:41 +02:00
parent 5761d6bbf7
commit 9d11493f33

View File

@ -21,7 +21,7 @@ def option(*args, **kwargs):
if not hasattr(f, "options"):
f.options = []
new_args = [i for i in args if i]
f.options.append((new_args, kwargs))
f.options.insert(0, (new_args, kwargs))
return f
return decorate