Skip to content

Commit cf75dc4

Browse files
authored
Merge pull request #9286 from alekla01/alekla01-include_check-patch-1
travis: Add include_check job
2 parents 1568be0 + fc41ea9 commit cf75dc4

File tree

1 file changed

+9
-0
lines changed

1 file changed

+9
-0
lines changed

.travis.yml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -306,6 +306,15 @@ matrix:
306306
- ! git grep -q --ignore-case "gnu general public";
307307
- ! git grep -q --ignore-case "gnu library general public";
308308

309+
- env:
310+
- NAME=include_check
311+
script:
312+
- echo 'Checking that there are no '#include "mbed.h"' in code where it should not be'
313+
- |
314+
! git grep '^#include\s["'"']mbed.h['"'"]$' -- '*.c' '*.h' '*.cpp' '*.hpp' \
315+
':!*platform_mbed.h' ':!*TESTS/*' ':!TEST_APPS/' ':!UNITTESTS/' \
316+
':!*tests/*' ':!*targets/*' ':!*TARGET_*' ':!*unsupported/*'
317+
309318
- env:
310319
- NAME=psa-autogen
311320
script:

0 commit comments

Comments
 (0)