File tree Expand file tree Collapse file tree 2 files changed +38
-0
lines changed Expand file tree Collapse file tree 2 files changed +38
-0
lines changed Original file line number Diff line number Diff line change 32
32
33
33
- run : python3 $PWD/scripts/build_all_examples.py
34
34
- run : python3 $PWD/testsuite/run.py
35
+ - run : python3 $PWD/scripts/check_readme.py
35
36
36
37
win-build :
37
38
name : Build and test on Windows
Original file line number Diff line number Diff line change
1
+ #! /usr/bin/env python3
2
+
3
+ import os
4
+ import sys
5
+ import config
6
+ import config .user_input .console
7
+ from build_all_examples import run_program
8
+
9
+ from config .boards import list_of_boards
10
+
11
+ script_dir = os .path .dirname (__file__ )
12
+ ADL_root_dir = os .path .abspath (os .path .join (script_dir , ".." ))
13
+ top_readme_file = os .path .join (ADL_root_dir , "README.md" )
14
+
15
+ undocumented = []
16
+
17
+ error = \
18
+ """Next boards were not mentioned in the top README.md file!
19
+ Please, append each of them to the table in the Board List section.
20
+ """
21
+
22
+ with open (top_readme_file , 'r' , encoding = 'utf-8' ) as file :
23
+ lines = [line for line in file ]
24
+
25
+ # No error on Custom_Board:
26
+ lines .append ("[Custom_Board]" )
27
+
28
+ for board in list_of_boards ():
29
+ text = f"[{ board } ]"
30
+ found = [line for line in lines if text in line ]
31
+ if not found :
32
+ undocumented .append (board )
33
+
34
+ if undocumented :
35
+ print (error )
36
+ print (undocumented )
37
+ sys .exit (1 )
You can’t perform that action at this time.
0 commit comments