From 36026ec0a05d74776114ddf5aee096fbda9bc7ee Mon Sep 17 00:00:00 2001 From: Boris Kolpackov Date: Fri, 16 Mar 2018 14:25:17 +0200 Subject: Redo pkg-status output --- bpkg/pkg-status.cli | 97 +++++++++++++++++++++++++++++++++++------------------ 1 file changed, 64 insertions(+), 33 deletions(-) (limited to 'bpkg/pkg-status.cli') diff --git a/bpkg/pkg-status.cli b/bpkg/pkg-status.cli index 6157c4d..09c6b2c 100644 --- a/bpkg/pkg-status.cli +++ b/bpkg/pkg-status.cli @@ -32,11 +32,11 @@ namespace bpkg respectively. Note that the status is written to \cb{STDOUT}, not \cb{STDERR}. - The status output format is regular. If several packages were specified, - then each line starts with the package name (and version, if specified) - followed by '\cb{:}'. Then comes one of the status words listed below. - Some of them can be optionally followed by '\cb{,}' (no spaces) and a - sub-status word. + The status output format is regular with components separated with + spaces. Each line starts with the package name (and version, if + specified) followed by one of the status words listed below. Some of + them can be optionally followed by '\cb{,}' (no spaces) and a sub-status + word. \dl| @@ -73,58 +73,65 @@ namespace bpkg If only the package name was specified without the package version, then the \cb{available} status word is followed by the list of available - versions. The last version on this list may have the \cb{sys:} prefix - indicating an available system version. Such a system version may be - the special '\cb{?}' value indicating that a package may or may not - be available from the system and its version is unknown. + versions. If the \cb{--system} option is specified, then the last version + in this list may have the \cb{sys:} prefix indicating an available system + version. Such a system version may be the special '\cb{?}' value + indicating that a package may or may not be available from the system and + that its version is unknown. Similarly, if only the package name was specified, then the \cb{fetched}, \cb{unpacked}, \cb{configured}, and \cb{broken} status words are followed - by the version of the package. After the package version, these status - words may be followed by one or more sub-status words. Currently, these - can be \cb{hold_package} (package should not be automatically dropped) and - \cb{hold_version} (package should not be automatically upgraded). Finally, - if only the package name was specified and newer versions are available - from some of the repositories, then the sub-status word is followed - by '\cb{;}', the \cb{available} status word, and the list of newer - versions. + by the version of the package. If newer versions are available, then the + package version is followed by the \cb{available} status word and the + list of newer versions. + + If the package name was specified with the version, then only the status + (such as, \cb{configured}, \cb{available}, etc.) of this version is + printed. + + If a package is being held, then its name is printed prefixed with + '\cb{!}'. Similarly, if a package version is being held, then the version + is printed prefixed with '\cb{!}'. Held packages and held versions were + selected by the user and are not automatically dropped and upgraded, + respectively. Below are some examples, assuming the configuration has \cb{libfoo} - \cb{1.0.0} configured and held as well as \cb{libfoo} \cb{1.1.0} and - \cb{1.1.1} available from source and \cb{1.1.0} from the system. + \cb{1.0.0} configured and held (both package and version) as well as + \cb{libfoo} \cb{1.1.0} and \cb{1.1.1} available from source and + \cb{1.1.0} from the system. \ bpkg status libbar - unknown + libbar unknown bpkg status libbar/1.0.0 - unknown + libbar/1.0.0 unknown bpkg status libfoo/1.0.0 - configured hold_package + !libfoo/1.0.0 configured !1.0.0 bpkg status libfoo/1.1.0 - available 1.1.0 sys:1.1.0 + libfoo/1.1.0 available 1.1.0 - bpkg status libfoo/1.1.1 - available + bpkg status --system libfoo/1.1.0 + libfoo/1.1.0 available 1.1.0 sys:1.1.0 bpkg status libfoo - configured 1.0.0 hold_package; available 1.1.0 1.1.1 sys:1.1.0 + !libfoo configured !1.0.0 available 1.1.0 1.1.1 - bpkg status libfoo/1.0.0 libbar - libfoo/1.0.0: configured hold_package - libbar: unknown + bpkg status libfoo/1.1.1 libbar + libfoo/1.1.1 available 1.1.1 + libbar unknown \ Assuming now that we dropped \cb{libfoo} from the configuration: \ bpkg status libfoo/1.0.0 - unknown + libfoo/1.0.0 unknown bpkg status libfoo - available 1.1.0 1.1.1 sys:1.1.0 + libfoo available 1.1.0 1.1.1 \ And assuming now that we built \cb{libfoo} as a system package with @@ -132,8 +139,7 @@ namespace bpkg \ bpkg status libfoo - configured,system * hold_package; available 1.1.0 1.1.1 sys:1.1.0 - unknown + !libfoo configured,system * available 1.1.0 1.1.1 \ " @@ -152,5 +158,30 @@ namespace bpkg { "Also print the status of all dependencies, recursively." } + + bool --constraint + { + "Print version constraints for dependencies." + } + + bool --system + { + "Check the availability of packages from the system." + } + + bool --no-hold + { + "Don't print the package or version hold status." + } + + bool --no-hold-package + { + "Don't print the package hold status." + } + + bool --no-hold-version + { + "Don't print the version hold status." + } }; } -- cgit v1.1