spack spec: don't show normalize + no hash for non concrete specs (#6417)
Showing "Normalize" on output doesn't give users additional information, as this step is essentially an implementation detail of concretization. This PR skips it and shows just the input spec and the concretized one. Printing partial hashes for input spec has been disabled.
This commit is contained in:
parent
ddb55c2b26
commit
f6ead27b5b
@ -62,7 +62,6 @@ def spec(parser, args):
|
|||||||
name_fmt = '$.' if args.namespaces else '$_'
|
name_fmt = '$.' if args.namespaces else '$_'
|
||||||
kwargs = {'cover': args.cover,
|
kwargs = {'cover': args.cover,
|
||||||
'format': name_fmt + '$@$%@+$+$=',
|
'format': name_fmt + '$@$%@+$+$=',
|
||||||
'hashes': args.long or args.very_long,
|
|
||||||
'hashlen': None if args.very_long else 7,
|
'hashlen': None if args.very_long else 7,
|
||||||
'show_types': args.types,
|
'show_types': args.types,
|
||||||
'install_status': args.install_status}
|
'install_status': args.install_status}
|
||||||
@ -75,16 +74,12 @@ def spec(parser, args):
|
|||||||
print(spec.to_yaml())
|
print(spec.to_yaml())
|
||||||
continue
|
continue
|
||||||
|
|
||||||
# Print some diagnostic info by default.
|
kwargs['hashes'] = False # Always False for input spec
|
||||||
print("Input spec")
|
print("Input spec")
|
||||||
print("--------------------------------")
|
print("--------------------------------")
|
||||||
print(spec.tree(**kwargs))
|
print(spec.tree(**kwargs))
|
||||||
|
|
||||||
print("Normalized")
|
kwargs['hashes'] = args.long or args.very_long
|
||||||
print("--------------------------------")
|
|
||||||
spec.normalize()
|
|
||||||
print(spec.tree(**kwargs))
|
|
||||||
|
|
||||||
print("Concretized")
|
print("Concretized")
|
||||||
print("--------------------------------")
|
print("--------------------------------")
|
||||||
spec.concretize()
|
spec.concretize()
|
||||||
|
Loading…
Reference in New Issue
Block a user