Add "spack versions --new" flag to only show new versions (#20030)

* [cmd versions] add spack versions --new flag to only fetch new versions

format

[cmd versions] rename --latest to --newest and add --remote-only

[cmd versions] add tests for --remote-only and --new

format

[cmd versions] update shell tab completion

[cmd versions] remove test for --remote-only --new which gives empty output

[cmd versions] final rename

format

* add brillig mock package

* add test for spack versions --new

* [brillig] format

* [versions] increase test coverage

* Update lib/spack/spack/cmd/versions.py

Co-authored-by: Massimiliano Culpo <massimiliano.culpo@gmail.com>

* Update lib/spack/spack/cmd/versions.py

Co-authored-by: Massimiliano Culpo <massimiliano.culpo@gmail.com>

Co-authored-by: Massimiliano Culpo <massimiliano.culpo@gmail.com>
This commit is contained in:
vvolkl
2020-12-07 16:29:10 +01:00
committed by GitHub
parent b4ed4fb226
commit ed258ca9e9
4 changed files with 80 additions and 18 deletions

View File

@@ -1649,7 +1649,7 @@ _spack_verify() {
_spack_versions() {
if $list_options
then
SPACK_COMPREPLY="-h --help -s --safe-only -c --concurrency"
SPACK_COMPREPLY="-h --help -s --safe --safe-only -r --remote -n --new -c --concurrency"
else
_all_packages
fi