tools/codeformat.py: Include more ports .c/.h files in formatting.
This adds a rule to cover all ports/**/*.[ch] file to the code formatting list. Explicit exclusions are also added for code in ports/ which is third party, or which requires a lot of reformatting. Signed-off-by: Damien George <damien@micropython.org>
This commit is contained in:
parent
71a64545a8
commit
fb10d15d47
@ -44,22 +44,37 @@ PATHS = [
|
|||||||
"shared/timeutils/*.[ch]",
|
"shared/timeutils/*.[ch]",
|
||||||
"shared/runtime/*.[ch]",
|
"shared/runtime/*.[ch]",
|
||||||
"mpy-cross/*.[ch]",
|
"mpy-cross/*.[ch]",
|
||||||
"ports/*/*.[ch]",
|
"ports/**/*.[ch]",
|
||||||
"ports/windows/msvc/**/*.[ch]",
|
|
||||||
"ports/nrf/modules/nrf/*.[ch]",
|
|
||||||
"py/*.[ch]",
|
"py/*.[ch]",
|
||||||
# Python
|
# Python
|
||||||
"drivers/**/*.py",
|
"drivers/**/*.py",
|
||||||
"examples/**/*.py",
|
"examples/**/*.py",
|
||||||
"extmod/**/*.py",
|
"extmod/**/*.py",
|
||||||
"ports/**/*.py",
|
"ports/**/*.py",
|
||||||
"ports/mimxrt/**/*.[ch]",
|
|
||||||
"py/**/*.py",
|
"py/**/*.py",
|
||||||
"tools/**/*.py",
|
"tools/**/*.py",
|
||||||
"tests/**/*.py",
|
"tests/**/*.py",
|
||||||
]
|
]
|
||||||
|
|
||||||
EXCLUSIONS = [
|
EXCLUSIONS = [
|
||||||
|
# The cc3200 port is not fully formatted yet.
|
||||||
|
"ports/cc3200/*/*.[ch]",
|
||||||
|
# The nrf port is not fully formatted yet.
|
||||||
|
"ports/nrf/boards/*.[ch]",
|
||||||
|
"ports/nrf/device/*.[ch]",
|
||||||
|
"ports/nrf/drivers/*.[ch]",
|
||||||
|
"ports/nrf/modules/ble/*.[ch]",
|
||||||
|
"ports/nrf/modules/board/*.[ch]",
|
||||||
|
"ports/nrf/modules/machine/*.[ch]",
|
||||||
|
"ports/nrf/modules/music/*.[ch]",
|
||||||
|
"ports/nrf/modules/ubluepy/*.[ch]",
|
||||||
|
"ports/nrf/modules/uos/*.[ch]",
|
||||||
|
"ports/nrf/modules/utime/*.[ch]",
|
||||||
|
# STM32 USB dev/host code is mostly 3rd party.
|
||||||
|
"ports/stm32/usbdev/**/*.[ch]",
|
||||||
|
"ports/stm32/usbhost/**/*.[ch]",
|
||||||
|
# Teensy core code is 3rd party.
|
||||||
|
"ports/teensy/core/*.[ch]",
|
||||||
# STM32 build includes generated Python code.
|
# STM32 build includes generated Python code.
|
||||||
"ports/*/build*",
|
"ports/*/build*",
|
||||||
# not real python files
|
# not real python files
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user