From 6218fc7cb0161ea115ad1cd57af5363923a47dd1 Mon Sep 17 00:00:00 2001 From: Daniel Mach Date: Thu, 9 May 2024 14:36:31 +0200 Subject: [PATCH] Improve 'getbinaries' command by ignoring source and debuginfo filters when a binary name is specified --- .../getbinaries-project-package-repo-arch-file.feature | 2 ++ osc/commandline.py | 5 +++++ 2 files changed, 7 insertions(+) diff --git a/behave/features/getbinaries-project-package-repo-arch-file.feature b/behave/features/getbinaries-project-package-repo-arch-file.feature index 5c5678df..2e816f81 100644 --- a/behave/features/getbinaries-project-package-repo-arch-file.feature +++ b/behave/features/getbinaries-project-package-repo-arch-file.feature @@ -32,6 +32,7 @@ Scenario: Run `osc getbinaries ` where f When I execute osc with args "getbinaries test:factory multibuild-pkg standard x86_64 multibuild-pkg-1-1.src.rpm" Then directory listing of "{context.osc.temp}/binaries/" is """ + multibuild-pkg-1-1.src.rpm """ @@ -47,6 +48,7 @@ Scenario: Run `osc getbinaries ` where f When I execute osc with args "getbinaries test:factory multibuild-pkg standard x86_64 multibuild-pkg-debuginfo-1-1.x86_64.rpm" Then directory listing of "{context.osc.temp}/binaries/" is """ + multibuild-pkg-debuginfo-1-1.x86_64.rpm """ diff --git a/osc/commandline.py b/osc/commandline.py index 2ae6baab..f07c06dc 100644 --- a/osc/commandline.py +++ b/osc/commandline.py @@ -8151,6 +8151,11 @@ Please submit there instead, or use --nodevelproject to force direct submission. else: package = [package] + if binary is not None: + output.print_msg("Binary filename was specified, ignoring source and debuginfo filters", print_to="debug") + opts.sources = True + opts.debuginfo = True + # Set binary target directory and create if not existing target_dir = os.path.normpath(opts.destdir) if not os.path.isdir(target_dir):