From d4e714bb2efc3a5428cf533cd3df4a671a6d44b3 Mon Sep 17 00:00:00 2001 From: Todd Gamblin <tgamblin@llnl.gov> Date: Sat, 14 Jan 2023 16:08:40 -0800 Subject: spack list: add `--count` option (#34950) Sometimes I just want to know how many packages of a certain type there are. - [x] add `--count` option to `spack list` that output the number of packages that *would* be listed. ```console > spack list --count 6864 > spack list --count py- 2040 > spack list --count r- 1162 ``` --- share/spack/spack-completion.bash | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'share') diff --git a/share/spack/spack-completion.bash b/share/spack/spack-completion.bash index 83fb689028..8d1bd8ce98 100755 --- a/share/spack/spack-completion.bash +++ b/share/spack/spack-completion.bash @@ -1197,7 +1197,7 @@ _spack_license_update_copyright_year() { _spack_list() { if $list_options then - SPACK_COMPREPLY="-h --help -d --search-description --format --update -v --virtuals -t --tag" + SPACK_COMPREPLY="-h --help -d --search-description --format -v --virtuals -t --tag --count --update" else _all_packages fi -- cgit v1.2.3-70-g09d2