spack checksum: show long flags in usage output (#40407)

This commit is contained in:
Harmen Stoppels 2023-10-26 14:48:35 +02:00 committed by GitHub
parent 86520abb68
commit 1c8073c21f
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
3 changed files with 13 additions and 13 deletions

View file

@ -37,30 +37,30 @@ def setup_parser(subparser):
help="don't clean up staging area when command completes", help="don't clean up staging area when command completes",
) )
subparser.add_argument( subparser.add_argument(
"-b",
"--batch", "--batch",
"-b",
action="store_true", action="store_true",
default=False, default=False,
help="don't ask which versions to checksum", help="don't ask which versions to checksum",
) )
subparser.add_argument( subparser.add_argument(
"-l",
"--latest", "--latest",
"-l",
action="store_true", action="store_true",
default=False, default=False,
help="checksum the latest available version", help="checksum the latest available version",
) )
subparser.add_argument( subparser.add_argument(
"-p",
"--preferred", "--preferred",
"-p",
action="store_true", action="store_true",
default=False, default=False,
help="checksum the known Spack preferred version", help="checksum the known Spack preferred version",
) )
modes_parser = subparser.add_mutually_exclusive_group() modes_parser = subparser.add_mutually_exclusive_group()
modes_parser.add_argument( modes_parser.add_argument(
"-a",
"--add-to-package", "--add-to-package",
"-a",
action="store_true", action="store_true",
default=False, default=False,
help="add new versions to package", help="add new versions to package",

View file

@ -681,7 +681,7 @@ _spack_change() {
_spack_checksum() { _spack_checksum() {
if $list_options if $list_options
then then
SPACK_COMPREPLY="-h --help --keep-stage -b --batch -l --latest -p --preferred -a --add-to-package --verify -j --jobs" SPACK_COMPREPLY="-h --help --keep-stage --batch -b --latest -l --preferred -p --add-to-package -a --verify -j --jobs"
else else
_all_packages _all_packages
fi fi

View file

@ -906,14 +906,14 @@ complete -c spack -n '__fish_spack_using_command checksum' -s h -l help -f -a he
complete -c spack -n '__fish_spack_using_command checksum' -s h -l help -d 'show this help message and exit' complete -c spack -n '__fish_spack_using_command checksum' -s h -l help -d 'show this help message and exit'
complete -c spack -n '__fish_spack_using_command checksum' -l keep-stage -f -a keep_stage complete -c spack -n '__fish_spack_using_command checksum' -l keep-stage -f -a keep_stage
complete -c spack -n '__fish_spack_using_command checksum' -l keep-stage -d 'don\'t clean up staging area when command completes' complete -c spack -n '__fish_spack_using_command checksum' -l keep-stage -d 'don\'t clean up staging area when command completes'
complete -c spack -n '__fish_spack_using_command checksum' -s b -l batch -f -a batch complete -c spack -n '__fish_spack_using_command checksum' -l batch -s b -f -a batch
complete -c spack -n '__fish_spack_using_command checksum' -s b -l batch -d 'don\'t ask which versions to checksum' complete -c spack -n '__fish_spack_using_command checksum' -l batch -s b -d 'don\'t ask which versions to checksum'
complete -c spack -n '__fish_spack_using_command checksum' -s l -l latest -f -a latest complete -c spack -n '__fish_spack_using_command checksum' -l latest -s l -f -a latest
complete -c spack -n '__fish_spack_using_command checksum' -s l -l latest -d 'checksum the latest available version' complete -c spack -n '__fish_spack_using_command checksum' -l latest -s l -d 'checksum the latest available version'
complete -c spack -n '__fish_spack_using_command checksum' -s p -l preferred -f -a preferred complete -c spack -n '__fish_spack_using_command checksum' -l preferred -s p -f -a preferred
complete -c spack -n '__fish_spack_using_command checksum' -s p -l preferred -d 'checksum the known Spack preferred version' complete -c spack -n '__fish_spack_using_command checksum' -l preferred -s p -d 'checksum the known Spack preferred version'
complete -c spack -n '__fish_spack_using_command checksum' -s a -l add-to-package -f -a add_to_package complete -c spack -n '__fish_spack_using_command checksum' -l add-to-package -s a -f -a add_to_package
complete -c spack -n '__fish_spack_using_command checksum' -s a -l add-to-package -d 'add new versions to package' complete -c spack -n '__fish_spack_using_command checksum' -l add-to-package -s a -d 'add new versions to package'
complete -c spack -n '__fish_spack_using_command checksum' -l verify -f -a verify complete -c spack -n '__fish_spack_using_command checksum' -l verify -f -a verify
complete -c spack -n '__fish_spack_using_command checksum' -l verify -d 'verify known package checksums' complete -c spack -n '__fish_spack_using_command checksum' -l verify -d 'verify known package checksums'
complete -c spack -n '__fish_spack_using_command checksum' -s j -l jobs -r -f -a jobs complete -c spack -n '__fish_spack_using_command checksum' -s j -l jobs -r -f -a jobs