summaryrefslogtreecommitdiff
path: root/lib
diff options
context:
space:
mode:
authorDr. Christian Tacke <58549698+ChristianTackeGSI@users.noreply.github.com>2019-12-28 00:21:15 +0100
committerTodd Gamblin <tgamblin@llnl.gov>2019-12-27 15:21:15 -0800
commit8ee75e19bd284a859e79a549c8781f00acc0e23f (patch)
treed25650fe75819b64669b8868c52d13d06f1670c3 /lib
parent2166a91ec50270fcc99a14021b3ab3539b302423 (diff)
downloadspack-8ee75e19bd284a859e79a549c8781f00acc0e23f.tar.gz
spack-8ee75e19bd284a859e79a549c8781f00acc0e23f.tar.bz2
spack-8ee75e19bd284a859e79a549c8781f00acc0e23f.tar.xz
spack-8ee75e19bd284a859e79a549c8781f00acc0e23f.zip
Improve info variant header (#14275)
In "spack info" the Variants header currently has two blank lines under it. That's too much. It looks like the actual content belongs to something else. Instead underline the headers to make things more obvious.
Diffstat (limited to 'lib')
-rw-r--r--lib/spack/spack/cmd/info.py4
1 files changed, 3 insertions, 1 deletions
diff --git a/lib/spack/spack/cmd/info.py b/lib/spack/spack/cmd/info.py
index 37a1aeb0a4..a51ce6470f 100644
--- a/lib/spack/spack/cmd/info.py
+++ b/lib/spack/spack/cmd/info.py
@@ -106,7 +106,9 @@ class VariantFormatter(object):
yield ' None'
else:
yield ' ' + self.fmt % self.headers
- yield '\n'
+ underline = tuple([l * "=" for l in self.column_widths])
+ yield ' ' + self.fmt % underline
+ yield ''
for k, v in sorted(self.variants.items()):
name = textwrap.wrap(
'{0} [{1}]'.format(k, self.default(v)),