Skip to content

Uncrustify code (clang-format + meson format) - #86

Merged
sinuscosinustan merged 4 commits into
mainfrom
uncrustify
Apr 25, 2026
Merged

sinuscosinustan merged 4 commits into
mainfrom
uncrustify

Conversation

@sinuscosinustan

@sinuscosinustan sinuscosinustan commented Apr 25, 2026 •

Copy link
Copy Markdown
Collaborator

As suggested in #85, add the Linux kernel clang-format config (with AlignConsecutiveMacros: true and AlignTrailingComments: true added) and ran it. This also adds a CI job to ensure that both the C code, as well as the meson build files are compliant with the formatter configs.

@sinuscosinustan
sinuscosinustan force-pushed the uncrustify branch 2 times, most recently from b11cf97 to 927194b Compare April 25, 2026 11:50
As suggested in a recent PR, add the kernel clang-format configuration
to this project with slight modifications. For better readability, the
following values were added or modified:

```
AlignConsecutiveMacros: true
AlignTrailingComments: true
```

Ignore src/ccan as this is vendored code.

Link: #85 (comment)
Signed-off-by: Tan Siewert <tan@siewert.io>
After the introduction of clang-format, re-format src/ completely using
`ninja -C build clang-format`.

Signed-off-by: Tan Siewert <tan@siewert.io>
Re-format the meson configs using `meson format`

Signed-off-by: Tan Siewert <tan@siewert.io>
@sinuscosinustan
sinuscosinustan force-pushed the uncrustify branch 2 times, most recently from 0ba38f3 to bdca6ba Compare April 25, 2026 14:02
Ensure that new code follows the configured clang-format rules and meson
formatter.

Signed-off-by: Tan Siewert <tan@siewert.io>
@sinuscosinustan
sinuscosinustan merged commit 3fd2e94 into main Apr 25, 2026
5 checks passed
@sinuscosinustan
sinuscosinustan deleted the uncrustify branch April 25, 2026 15:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant