aboutsummaryrefslogtreecommitdiff
path: root/libs/utils/platforms/__init__.py
blob: b6558e37e64d18bdcdb532003351c667ebc7fb16 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
import json
import os
from conf import JsonConf

# Add identifiers for each of the platforms we have JSON descriptors for
this_dir = os.path.dirname(__file__)
for file_name in os.listdir(this_dir):
    name, ext = os.path.splitext(file_name)
    if ext == '.json':
        platform = JsonConf(os.path.join(this_dir, file_name)).load()
        identifier = name.replace('-', '_')
        globals()[identifier] = platform