From 1d836fd7ce5cff1cefa94f52362f9f57b4d142fc Mon Sep 17 00:00:00 2001 From: Michael Andres Date: Fri, 11 Apr 2014 15:04:05 +0200 Subject: [PATCH] zypper packages: Remove conflicting short options (-r repo/reconmmends) This fixes #45 --- doc/zypper.8 | 8 ++++---- src/Zypper.cc | 32 ++++++++++++++++---------------- 2 files changed, 20 insertions(+), 20 deletions(-) diff --git a/doc/zypper.8 b/doc/zypper.8 index 7bacfae..f9adb83 100644 --- a/doc/zypper.8 +++ b/doc/zypper.8 @@ -955,16 +955,16 @@ Show only installed packages. .I \-u, \-\-uninstalled\-only Show only packages which are not installed. .TP -.I \-o, \-\-orphaned +.I \-\-orphaned Show packages which are orphaned (without repository). .TP -.I \-s, \-\-suggested +.I \-\-suggested Show packages which are suggested. .TP -.I \-r, \-\-recommended +.I \-\-recommended Show packages which are recommeded. .TP -.I \-n, \-\-unneeded +.I \-\-unneeded Show packages which are unneeded. .TP diff --git a/src/Zypper.cc b/src/Zypper.cc index b23ec88..4308c9e 100644 --- a/src/Zypper.cc +++ b/src/Zypper.cc @@ -2053,19 +2053,19 @@ void Zypper::processCommandOptions() case ZypperCommand::PACKAGES_e: { static struct option options[] = { - {"repo", required_argument, 0, 'r'}, + {"repo", required_argument, 0, 'r'}, // rug compatibility option, we have --repo - {"catalog", required_argument, 0, 'c'}, - {"installed-only", no_argument, 0, 'i'}, - {"uninstalled-only", no_argument, 0, 'u'}, - {"orphaned", no_argument, 0, 'o'}, - {"suggested", no_argument, 0, 's'}, - {"recommended", no_argument, 0, 'r'}, - {"unneeded", no_argument, 0, 'n'}, - {"sort-by-name", no_argument, 0, 'N'}, - {"sort-by-repo", no_argument, 0, 'R'}, - {"sort-by-catalog", no_argument, 0, 0}, - {"help", no_argument, 0, 'h'}, + {"catalog", required_argument, 0, 'c'}, + {"installed-only", no_argument, 0, 'i'}, + {"uninstalled-only", no_argument, 0, 'u'}, + {"orphaned", no_argument, 0, 0 }, + {"suggested", no_argument, 0, 0 }, + {"recommended", no_argument, 0, 0 }, + {"unneeded", no_argument, 0, 0 }, + {"sort-by-name", no_argument, 0, 'N'}, + {"sort-by-repo", no_argument, 0, 'R'}, + {"sort-by-catalog", no_argument, 0, 0 }, + {"help", no_argument, 0, 'h'}, {0, 0, 0, 0} }; specific_options = options; @@ -2079,10 +2079,10 @@ void Zypper::processCommandOptions() "-r, --repo Just another means to specify repository.\n" "-i, --installed-only Show only installed packages.\n" "-u, --uninstalled-only Show only packages which are not installed.\n" - "-o, --orphaned Show packages which are orphaned (without repository).\n" - "-s, --suggested Show packages which are suggested.\n" - "-r, --recommended Show packages which are recommended.\n" - "-n, --unneeded Show packages which are unneeded.\n" + " --orphaned Show packages which are orphaned (without repository).\n" + " --suggested Show packages which are suggested.\n" + " --recommended Show packages which are recommended.\n" + " --unneeded Show packages which are unneeded.\n" "-N, --sort-by-name Sort the list by package name.\n" "-R, --sort-by-repo Sort the list by repository.\n" ); -- 2.7.4