1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
|
# Copyright 2013-2019 Lawrence Livermore National Security, LLC and other
# Spack Project Developers. See the top-level COPYRIGHT file for details.
#
# SPDX-License-Identifier: (Apache-2.0 OR MIT)
"""Schema for config.yaml configuration file.
.. literalinclude:: _spack_root/lib/spack/spack/schema/config.py
:lines: 13-
"""
#: Properties for inclusion in other schemas
properties = {
'config': {
'type': 'object',
'default': {},
'properties': {
'install_tree': {'type': 'string'},
'install_hash_length': {'type': 'integer', 'minimum': 1},
'install_path_scheme': {'type': 'string'},
'build_stage': {
'oneOf': [
{'type': 'string'},
{'type': 'array',
'items': {'type': 'string'}}],
},
'extensions': {
'type': 'array',
'items': {'type': 'string'}
},
'template_dirs': {
'type': 'array',
'items': {'type': 'string'}
},
'module_roots': {
'type': 'object',
'additionalProperties': False,
'properties': {
'tcl': {'type': 'string'},
'lmod': {'type': 'string'},
'dotkit': {'type': 'string'},
},
'deprecatedProperties': {
'properties': ['dotkit'],
'message': 'specifying a "{property}" module root has no '
'effect [support for {property} module files'
' has been dropped]',
'error': False
},
},
'source_cache': {'type': 'string'},
'misc_cache': {'type': 'string'},
'verify_ssl': {'type': 'boolean'},
'install_missing_compilers': {'type': 'boolean'},
'debug': {'type': 'boolean'},
'checksum': {'type': 'boolean'},
'locks': {'type': 'boolean'},
'dirty': {'type': 'boolean'},
'build_language': {'type': 'string'},
'build_jobs': {'type': 'integer', 'minimum': 1},
'ccache': {'type': 'boolean'},
'db_lock_timeout': {'type': 'integer', 'minimum': 1},
'package_lock_timeout': {
'anyOf': [
{'type': 'integer', 'minimum': 1},
{'type': 'null'}
],
},
},
},
}
#: Full schema with metadata
schema = {
'$schema': 'http://json-schema.org/schema#',
'title': 'Spack core configuration file schema',
'type': 'object',
'additionalProperties': False,
'properties': properties,
}
|