@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"version": 6,
|
"version": 6,
|
||||||
"include": [
|
"include": [
|
||||||
"../../../hw/bsp/BoardPresets.json"
|
"../hw/bsp/BoardPresets.json"
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"version": 6,
|
"version": 6,
|
||||||
"include": [
|
"include": [
|
||||||
"../../../hw/bsp/BoardPresets.json"
|
"../../hw/bsp/BoardPresets.json"
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
@@ -1,6 +0,0 @@
|
|||||||
{
|
|
||||||
"version": 6,
|
|
||||||
"include": [
|
|
||||||
"../../../hw/bsp/BoardPresets.json"
|
|
||||||
]
|
|
||||||
}
|
|
@@ -1,6 +0,0 @@
|
|||||||
{
|
|
||||||
"version": 6,
|
|
||||||
"include": [
|
|
||||||
"../../../hw/bsp/BoardPresets.json"
|
|
||||||
]
|
|
||||||
}
|
|
@@ -1,6 +0,0 @@
|
|||||||
{
|
|
||||||
"version": 6,
|
|
||||||
"include": [
|
|
||||||
"../../../hw/bsp/BoardPresets.json"
|
|
||||||
]
|
|
||||||
}
|
|
@@ -1,6 +0,0 @@
|
|||||||
{
|
|
||||||
"version": 6,
|
|
||||||
"include": [
|
|
||||||
"../../../hw/bsp/BoardPresets.json"
|
|
||||||
]
|
|
||||||
}
|
|
@@ -1,6 +0,0 @@
|
|||||||
{
|
|
||||||
"version": 6,
|
|
||||||
"include": [
|
|
||||||
"../../../hw/bsp/BoardPresets.json"
|
|
||||||
]
|
|
||||||
}
|
|
@@ -1,6 +0,0 @@
|
|||||||
{
|
|
||||||
"version": 6,
|
|
||||||
"include": [
|
|
||||||
"../../../hw/bsp/BoardPresets.json"
|
|
||||||
]
|
|
||||||
}
|
|
@@ -1,6 +0,0 @@
|
|||||||
{
|
|
||||||
"version": 6,
|
|
||||||
"include": [
|
|
||||||
"../../../hw/bsp/BoardPresets.json"
|
|
||||||
]
|
|
||||||
}
|
|
@@ -1,6 +0,0 @@
|
|||||||
{
|
|
||||||
"version": 6,
|
|
||||||
"include": [
|
|
||||||
"../../../hw/bsp/BoardPresets.json"
|
|
||||||
]
|
|
||||||
}
|
|
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"version": 6,
|
"version": 6,
|
||||||
"include": [
|
"include": [
|
||||||
"../../../hw/bsp/BoardPresets.json"
|
"../../hw/bsp/BoardPresets.json"
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"version": 6,
|
"version": 6,
|
||||||
"include": [
|
"include": [
|
||||||
"../../../hw/bsp/BoardPresets.json"
|
"../../hw/bsp/BoardPresets.json"
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
@@ -1,6 +0,0 @@
|
|||||||
{
|
|
||||||
"version": 6,
|
|
||||||
"include": [
|
|
||||||
"../../../hw/bsp/BoardPresets.json"
|
|
||||||
]
|
|
||||||
}
|
|
@@ -1,6 +0,0 @@
|
|||||||
{
|
|
||||||
"version": 6,
|
|
||||||
"include": [
|
|
||||||
"../../../hw/bsp/BoardPresets.json"
|
|
||||||
]
|
|
||||||
}
|
|
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"version": 6,
|
"version": 6,
|
||||||
"include": [
|
"include": [
|
||||||
"../../../hw/bsp/BoardPresets.json"
|
"../../hw/bsp/BoardPresets.json"
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
@@ -1,7 +1,7 @@
|
|||||||
#!/usr/bin/env python3
|
#!/usr/bin/env python3
|
||||||
import os
|
import os
|
||||||
import json
|
import json
|
||||||
|
from pathlib import Path
|
||||||
|
|
||||||
def main():
|
def main():
|
||||||
board_list = []
|
board_list = []
|
||||||
@@ -76,21 +76,23 @@ def main():
|
|||||||
], key=lambda x: x['name']
|
], key=lambda x: x['name']
|
||||||
)
|
)
|
||||||
|
|
||||||
with open("hw/bsp/BoardPresets.json", "w") as f:
|
path_boardpresets = "hw/bsp/BoardPresets.json"
|
||||||
|
with open(path_boardpresets, "w") as f:
|
||||||
f.write('{}\n'.format(json.dumps(presets, indent=2)))
|
f.write('{}\n'.format(json.dumps(presets, indent=2)))
|
||||||
|
|
||||||
# Generate presets for examples
|
# Generate presets for examples
|
||||||
presets = {
|
presets = {
|
||||||
"version": 6,
|
"version": 6,
|
||||||
"include": [
|
"include": [
|
||||||
"../../../hw/bsp/BoardPresets.json"
|
|
||||||
]
|
]
|
||||||
}
|
}
|
||||||
|
|
||||||
example_list = []
|
example_list = []
|
||||||
for root, dirs, files in os.walk("examples"):
|
for root, dirs, files in os.walk("examples"):
|
||||||
for file in files:
|
for file in files:
|
||||||
if file == "CMakeLists.txt":
|
# Filter out ESP-IDF CMakeLists.txt in src folder
|
||||||
|
if file == "CMakeLists.txt" and os.path.basename(root) != 'src':
|
||||||
|
presets['include'] = [os.path.relpath(path_boardpresets, root).replace(os.sep, '/')]
|
||||||
with open(os.path.join(root, 'CMakePresets.json'), 'w') as f:
|
with open(os.path.join(root, 'CMakePresets.json'), 'w') as f:
|
||||||
f.write('{}\n'.format(json.dumps(presets, indent=2)))
|
f.write('{}\n'.format(json.dumps(presets, indent=2)))
|
||||||
example_list.append(os.path.basename(root))
|
example_list.append(os.path.basename(root))
|
||||||
|
Reference in New Issue
Block a user