From 9d11493f33be5a0bdc2016e7d9e8bf6796112fd5 Mon Sep 17 00:00:00 2001 From: Daniel Mach Date: Tue, 20 Sep 2022 09:59:41 +0200 Subject: [PATCH] cmdln: Order options and arguments by the order of decorators in the source code --- osc/cmdln.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/osc/cmdln.py b/osc/cmdln.py index 5d69264d..5275e713 100644 --- a/osc/cmdln.py +++ b/osc/cmdln.py @@ -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