[llvm-dev] Creating my own “clang-format” style that can be used across multiple projects with the “BasedOnStyle” setting
David Blaikie via llvm-dev
llvm-dev at lists.llvm.org
Mon Dec 28 18:18:19 PST 2020
+MyDeveloper Day <mydeveloperday at gmail.com> who seems to be contributing
to/reviewing clang-format patches these days
Sounds like a nice to have feature - you can file feature requests in the
LLVM bugzilla (bugs.llvm.org). (perhaps it's already possible, but I don't
know enough about clang-format to say)
On Sun, Dec 20, 2020 at 4:29 PM Timothy Wrona via llvm-dev <
llvm-dev at lists.llvm.org> wrote:
> Hi,
>
> This is my first time reaching out to the llvm mailing list so I apologize
> if this is not the correct place to ask a question like this. (If it isn't
> please let me know where I should post this question.)
>
> I have multiple projects that I want to share a similar clang-format
> style, but I also want to be able to make minor tweaks between each project
> so they can be slightly different from one another if needed. Currently
> each project just has the same .clang-format file copied and pasted into
> its own repository, but it feels wrong because all of the style options are
> just duplicated from project to project and if I need to change one option
> I need to go across all projects and manually change it in all of them.
>
> I would like to create my own style that can be used with the
> "BasedOnStyle" option. That way I can specify that I want all of these
> projects to be based on the same custom style that would be kept in a
> shared location, and then I could easily override any project specific
> options on a per-project basis.
>
> I looked through the documentation and as far as I can tell, there doesn't
> appear to be any way to create your own style and save it so other projects
> can be based on the same style. I feel like this is something a lot of
> users would need (for example if a company wanted to define their own
> master style that all projects should follow).
>
> Is there any way to do this? And if not, how could I go about requesting
> such a feature be added?
>
> Thanks,
>
> Tim
> _______________________________________________
> LLVM Developers mailing list
> llvm-dev at lists.llvm.org
> https://lists.llvm.org/cgi-bin/mailman/listinfo/llvm-dev
>
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.llvm.org/pipermail/llvm-dev/attachments/20201228/16b16547/attachment.html>
More information about the llvm-dev
mailing list