- --repo -> man page
authorJan Kupec <jkupec@suse.cz>
Wed, 1 Aug 2007 13:30:29 +0000 (13:30 +0000)
committerJan Kupec <jkupec@suse.cz>
Wed, 1 Aug 2007 13:30:29 +0000 (13:30 +0000)
doc/zypper.8
src/zypper.cc

index 35123ea..7630d9f 100644 (file)
@@ -58,8 +58,8 @@ Names are not only package names but any symbols provided by packages:
 special characters from the shell.
 
 .TP
-\fI\-c, \-\-catalog\fR <catalog>
-Only from this catalog (FIXME not implemented yet)
+\fI\-r, \-\-repo\fR <alias>
+Install resolvables only from the repository specified by the alias.
 .TP
 \fI\-t, \-\-type\fR <resolvable_type>
 Type of resolvable (default: package)
@@ -83,8 +83,8 @@ List available updates.
 \fI\-t, --type\fR <resolvable_type>
 Type of resolvable (default: patch)
 .TP
-\fI\--from-repo\fR <repository_alias>
-Limit view to updates available from named repository
+\fI\-r, \-\-repo\fR <alias>
+List only updates from the repository specified by the alias.
 
 See also the NOTE at
 .BR update .
@@ -95,6 +95,9 @@ Remove resolvables.
 .PP
 Capability is usually a plain name, for details see the install command.
 .TP
+\fI\-r, \-\-repo\fR <alias>
+Operate only with resolvables from repository specified by alias.
+.TP
 \fI\-t, -\-type\fR <resolvable_type>
 Type of resolvable (default: package)
 .TP
@@ -111,8 +114,8 @@ Update all installed resolvables with newer versions, where applicable.
 \fI\-t, -\-type\fR <resolvable_type>
 Type of resolvable (default: patch)
 .TP
-\fI\--from-repo\fR <repository_alias>
-Limit to updates available from named repository
+\fI\-r, \-\-repo\fR <alias>
+Limit updates to repository specified by alias.
 .TP
 .I     \-\-skip\-interactive
 This will skip interactive patches, that is, those that need reboot,
@@ -128,9 +131,6 @@ description exists, like on the SUSE update servers. To operate on all
 packages for which there is a better version instead, select \fI--type
 package\fR which is also the default in rug compatibility mode.
 
-By using \fI--from-repo\fR one can follow a specific repository only
-with updates.
-
 .TP
 \fBsearch\fR (\fBse\fR) [\fIoptions\fR] [\fBquerystring\fR] ...
 Search for resolvables matching given strings. * (any substring) and ? (any character) wildcards can also be used within search strings.
@@ -166,16 +166,16 @@ Show only resolvables that are already installed.
 .I \-u, \-\-uninstalled\-only
 Show only resolvables that are not currently installed.
 .TP
-\fI\-t, -\-type\fR [resolvable]
-Search only for resolvables of specified type.
+.I \-t, -\-type <type>
+Search only for resolvables of specified type. See the beginning of the subsection for the list of available resolvable types.
 .TP
-.I \-c, \-\-catalog
-Show only the resolvables from the catalog you specify. (not implemented yet)
+.I \-r, \-\-repo <alias>
+Search only in the repository specified by the alias.
 .TP
 \fI    \-\-sort\-by\-name\fR
 Sort resolvables by name (default).
 .TP
-\fI    \-\-sort\-by\-catalog\fR
+\fI    \-\-sort\-by\-repo\fR
 Sort resolvables by catalog, not by name.
 
 .SS Patch Management
@@ -184,21 +184,31 @@ Sort resolvables by catalog, not by name.
 .B patch-check (pchk)
 Check for patches. Displays a count of applicable patches and how many
 of them have the security category.
-
-Exit status: 0 - no patches, 1 - non-security patches, 2 - security patches.
+.PP
+See also the EXIT CODES section for details on exit status of 0, 100, and 101
+returned by this command.
+.TP
+.I \-r, \-\-repo <alias>
+Check for patches only in the repository specified by the alias.
 
 .TP
 .B patches (pch)
 List patches. Lists all patches that are available, including
 installed and not applicable ones.
+.TP
+.I \-r, \-\-repo <alias>
+Check for patches only in the repository specified by the alias.
 
 .TP
 .B patch-info <name> ...
 Displays full info for the specified patches.
+.TP
+.I \-r, \-\-repo <alias>
+Work only with the repository specified by the alias.
  
 .SS Repository Management
 
-.LP
+.PP
 zypper is able to work with YaST, YUM, and aptrpm
 repositories, ZENworks 7 Linux Management, ZENworks 6.6.x Linux
 Management servers, as well as local files.
@@ -218,7 +228,7 @@ Add the repository as disabled.
 .TP
 \fI\-n, \-\-no\-refresh\fR 
 Add the repository with auto-refresh disabled.
-.TP
+.PP
 NOTE: This command does not automatically refresh the newly added repositories. You have to use the \fBrefresh\fR command after finishing your modifications to repositories with \fB*repo\fR commands.
 
 .TP
@@ -356,7 +366,7 @@ zypper is designed to be compatible with rug, which is a command\-line interface
 ZENworks distinguishes services and catalogs. A service is
 added by URI and contains one or more catalogs. Libzypp does not have
 this distinction (yet) but for compatibility it is able to use the same command
-and option names (service-add, --catalog) as rug.
+and option names (service-add, \-\-catalog) as rug.
 .LP
 Currently, a Repository in zypper is a synonym for both Service and Catalog in ZLM.
 .TP
@@ -371,7 +381,6 @@ zypper removerepo (rr)
 .I rug service-list (sl)
 zypper repos (lr)
 
-.LP 
 .SS Package Management Commands
 
 .TP
@@ -383,7 +392,7 @@ zypper install (in)
 Don't require user interaction. This option is implemented using zypper's non-interactive mode.
 .TP
 .I      \-\-agree\-to\-third\-party\-licenses
-This option is an alias to zypper's --auto-agree-with-licenses option.
+This option is an alias to zypper's \-\-auto-agree\-with\-licenses option.
 .RE
 
 .TP
@@ -402,10 +411,28 @@ zypper update (up)
 .TP
 .I \-y, \-\-no\-confirm
 Don't require user interaction. This option is implemented using zypper's non-interactive mode.
-.I    , \-\-agree\-to\-third\-party\-licenses
-This option is an alias to zypper's --auto-agree-with-licenses option.
+.TP
+.I      \-\-agree\-to\-third\-party\-licenses
+This option is an alias to zypper's \-\-auto-agree\-with\-licenses option.
 .RE
 
+.TP
+.I rug search (se)
+zypper search (se)
+.TP
+\fI    \-\-sort\-by\-catalog\fR
+Sort resolvables by catalog, not by name. This option is an alias to zypper's
+\-\-sort\-by\-repo option.
+
+.SS Other Compatibility Notes
+
+.TP
+\fI\-c, \-\-catalog\fR <catalog>
+This option is an alias to zypper's \-\-repo <alias> and it will restrict
+the operation of commands like search, install, etc to the repository specified
+by the alias.
+
+
 .SH "NOTE"
 .LP
 Currently, zypper can be run only by user with root privileges.
index 41a0ad6..aa4520a 100644 (file)
@@ -445,7 +445,7 @@ int one_command(const ZypperCommand & command, int argc, char **argv)
       "\n"
       "  Command options:\n"
       "-t, --type <type>   Type of resolvable (package, patch, pattern, product) (default: patch)\n"
-      "-r, --repo <alias>  Work only with updates from repository specified by alias.\n"
+      "-r, --repo <alias>  List only updates from the repository specified by the alias.\n"
       "    --best-effort   Do a 'best effort' approach to update, updates to a lower than latest-and-greatest version are also acceptable.\n"
     );
   }
@@ -469,7 +469,7 @@ int one_command(const ZypperCommand & command, int argc, char **argv)
       "  Command options:\n"
       "\n"
       "-t, --type <type>               Type of resolvable (package, patch, pattern, product) (default: patch)\n"
-      "-r, --repo <alias>              Work only with updates from repository specified by alias.\n"
+      "-r, --repo <alias>              Limit updates to the repository specified by the alias.\n"
       "    --skip-interactive          Skip interactive updates\n"
       "-l, --auto-agree-with-licenses  Automatically say 'yes' to third party license confirmation prompt.\n"
       "                                See man zypper for more details.\n"
@@ -515,8 +515,8 @@ int one_command(const ZypperCommand & command, int argc, char **argv)
       "-c, --case-sensitive       Perform case-sensitive search.\n"
       "-i, --installed-only       Show only packages that are already installed.\n"
       "-u, --uninstalled-only     Show only packages that are not currently installed.\n"
-      "-t, --type                 Search only for packages of the specified type.\n"
-      "-r, --repo <alias>         Search only in repository specified by alias.\n"
+      "-t, --type <type>          Search only for packages of the specified type.\n"
+      "-r, --repo <alias>         Search only in the repository specified by the alias.\n"
       "    --sort-by-name         Sort packages by name (default).\n"
       "    --sort-by-repo         Sort packages by repository.\n"
       "\n"
@@ -539,7 +539,7 @@ int one_command(const ZypperCommand & command, int argc, char **argv)
       "\n"
       "  Command options:\n"
       "\n"
-      "-r, --repo <alias>  Check for patches only in repository specified by alias.\n"
+      "-r, --repo <alias>  Check for patches only in the repository specified by the alias.\n"
     );
   }
   else if (command == ZypperCommand::SHOW_PATCHES) {
@@ -558,7 +558,7 @@ int one_command(const ZypperCommand & command, int argc, char **argv)
       "\n"
       "  Command options:\n"
       "\n"
-      "-r, --repo <alias>  Check for patches only in repository specified by alias.\n"
+      "-r, --repo <alias>  Check for patches only in the repository specified by the alias.\n"
     );
   }
   else if (command == ZypperCommand::INFO) {
@@ -577,7 +577,7 @@ int one_command(const ZypperCommand & command, int argc, char **argv)
       "\n"
       "  Command options:\n"
       "\n"
-      "-r, --repo <alias>  Work only with the repository specified by alias.\n"
+      "-r, --repo <alias>  Work only with the repository specified by the alias.\n"
     );
   }
   // rug compatibility command, we have zypper info [-t <res_type>]
@@ -1104,8 +1104,10 @@ int one_command(const ZypperCommand & command, int argc, char **argv)
       cout << _("No resolvables found.") << endl;
     else {
       cout << endl;
-      if (copts.count("sort-by-catalog")) t.sort(1);
-      else t.sort(3); // sort by name
+      if (copts.count("sort-by-catalog") || copts.count("sort-by-repo"))
+        t.sort(1);
+      else
+        t.sort(3); // sort by name
       cout << t;
     }