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

clang-format config? #414

Closed
rpavlik opened this issue May 20, 2019 · 3 comments

Comments

Projects
None yet
2 participants
@rpavlik
Copy link
Contributor

commented May 20, 2019

In working on the code, I tend to accidentally not follow the style guide because it's a little unique (mostly the "no spaces in if(condition), etc" item) If this style is still the desired one and important, would be great if someone could make a clang-format (or other formatter) config file that enforced it.

@whitequark whitequark added the question label May 20, 2019

@whitequark

This comment has been minimized.

Copy link
Member

commented May 20, 2019

I generally agree, but I'm not sure how clang-format deals with partial reformats. As been discussed before, bulk formatting changes are a no-go, and if clang-format can only do one file at a time its usefulness seems limited here.

@rpavlik

This comment has been minimized.

Copy link
Contributor Author

commented May 20, 2019

I tend to use git clang-format to just reformat the changes currently staged, for projects where I can't format the whole thing.

@whitequark

This comment has been minimized.

Copy link
Member

commented May 20, 2019

Whoa, I had no idea that existed. I'm completely in favor of having a .clang-format file then and suggesting its use in guidelines. I'm not sure when I will get around it, so if you feel like making one, go ahead please.

@rpavlik rpavlik referenced this issue May 20, 2019

Closed

Clang format #416

@whitequark whitequark closed this May 23, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.