[pacman-dev] [PATCH 1/2] pacman-key: added verbose to commandline options
Allan McRae
allan at archlinux.org
Sun Nov 3 23:31:33 UTC 2019
On 4/11/19 3:14 am, Matthew Sexton wrote:
> Signed-off-by: Matthew Sexton <wsdmatty at gmail.com>
I'm OK with adding this option in a separate patch that does not use it.
But note in the commit message that it currently does nothing.
Couple of minor points below.
> ---
> scripts/pacman-key.sh.in | 5 ++++-
> 1 file changed, 4 insertions(+), 1 deletion(-)
>
> diff --git a/scripts/pacman-key.sh.in b/scripts/pacman-key.sh.in
> index 05aab0c2..a59dba52 100644
> --- a/scripts/pacman-key.sh.in
> +++ b/scripts/pacman-key.sh.in
> @@ -51,6 +51,7 @@ REFRESH=0
> UPDATEDB=0
> USE_COLOR='y'
> VERIFY=0
> +VERBOSE=0
>
> usage() {
> printf "pacman-key (pacman) %s\n" ${myver}
> @@ -77,6 +78,7 @@ usage() {
> printf -- "$(gettext " --populate Reload the default keys from the (given) keyrings\n\
> in '%s'")\n" "@pkgdatadir@/keyrings"
> printf -- "$(gettext " --refresh-keys Update specified or all keys from a keyserver")\n"
> + printf -- "$(gettext " --verbose Show extra information")\n"
> echo
> printf -- "$(gettext "Options:")\n"
> printf -- "$(gettext " --config <file> Use an alternate config file (instead of\n\
> @@ -541,7 +543,7 @@ OPT_SHORT="adefhlruvV"
> OPT_LONG=('add' 'config:' 'delete' 'edit-key' 'export' 'finger' 'gpgdir:'
> 'help' 'import' 'import-trustdb' 'init' 'keyserver:' 'list-keys' 'list-sigs'
> 'lsign-key' 'nocolor' 'populate' 'recv-keys' 'refresh-keys' 'updatedb'
> - 'verify' 'version')
> + 'verify' 'version' 'verbose')
These are in alphabetical order.
> if ! parseopts "$OPT_SHORT" "${OPT_LONG[@]}" -- "$@"; then
> exit 1 # E_INVALID_OPTION
> fi
> @@ -575,6 +577,7 @@ while (( $# )); do
> --refresh-keys) REFRESH=1 ;;
> -u|--updatedb) UPDATEDB=1 ;;
> -v|--verify) VERIFY=1 ;;
> + --verbose) VERBOSE=1 ;;
Align with spaces.
>
> -h|--help) usage; exit 0 ;;
> -V|--version) version; exit 0 ;;
>
More information about the pacman-dev
mailing list