Skip to content

build: Indent cmake consistently#7345

Merged
HuidaeCho merged 1 commit intoOSGeo:mainfrom
HuidaeCho:cmake_indentation
Apr 28, 2026
Merged

build: Indent cmake consistently#7345
HuidaeCho merged 1 commit intoOSGeo:mainfrom
HuidaeCho:cmake_indentation

Conversation

@HuidaeCho
Copy link
Copy Markdown
Member

This PR applies consistent indentation to a cmake file.

@github-actions github-actions Bot added the CMake label Apr 27, 2026
Copy link
Copy Markdown
Member

@echoix echoix left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Was this done manually or with a script? With a script, a tool, or linter, that could be run in pre-commit, it would prevent these kind of disreptencies to be created in the future.

The tool me and @nilason knows of isn't quite perfect (hard to configure to get something pleasant to read in all cases, and isn't creating potential merge conflicts easily) and we waited to have finished the initial implementation before formatting everything with a chosen style.

@m-kuhn
Copy link
Copy Markdown
Contributor

m-kuhn commented Apr 27, 2026

@echoix
Copy link
Copy Markdown
Member

echoix commented Apr 27, 2026

FTR: for QField we use https://github.com/cheshirekow/cmake-format-precommit

it's not perfect but can be tuned by making additional commands available if someone is motivated https://github.com/opengisch/QField/blob/master/.cmake-format.yaml

https://github.com/opengisch/QField/blob/c7fbab2b1bb5e048389d9ca68aa83e7b7edaa759/.pre-commit-config.yaml#L56-L62

Thanks for the reference, we should consider this soon

@HuidaeCho HuidaeCho merged commit c3bac51 into OSGeo:main Apr 28, 2026
26 checks passed
@github-actions github-actions Bot added this to the 8.6.0 milestone Apr 28, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants