Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add clang-format style #4251

Open
samuelfac opened this issue Jun 13, 2024 · 1 comment
Open

add clang-format style #4251

samuelfac opened this issue Jun 13, 2024 · 1 comment
Labels
enhancement New feature or request question Further information is requested

Comments

@samuelfac
Copy link

What problem are you trying to solve?

Format the code with clang-format style

Describe the solution you'd like

create a new style that will use ".clang-format" file from source project to format the code.

@samuelfac samuelfac added the enhancement New feature or request label Jun 13, 2024
@timtebeek
Copy link
Contributor

Hi @samuelfac ; I'm not too familiar with clang-format; would you mind explaining in some more detail exactly what you're after? Perhaps with some examples of a configuration file to take in and apply to projects?

You might know we already support various named styles, and even allow you to customize styles to your needs.
https://docs.openrewrite.org/concepts-explanations/styles
Could this be used to achieve what you're after already?

I'm not sure how widely used clang-format is, but it's a high bar for us to add two ways to do one thing; in this case to define how you want to define your project style.

There's also other competing standards like checkstyle and .editorconfig that on the surface seem similar, as are tools like spotless and Google Java format that do not allow customization. I'd be hesitant to add support for each of these and have to support all going forward.

What's the context behind your specific request for clang support?

@timtebeek timtebeek added the question Further information is requested label Jun 14, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request question Further information is requested
Projects
Status: No status
Development

No branches or pull requests

2 participants