-
Notifications
You must be signed in to change notification settings - Fork 12
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
Run indenter on the codebase? #131
Comments
Since this is a C repo, I highly recommend we take advantage of existing tools like uncrustify. There's also a GUI Frontend which can be used to generate a configuration for the indenter with a real-time preview. I've used it before and it's very capable. |
Made a dev branch for testing out code formatting with uncrustify. |
@leandro-lucarella-sociomantic wondering if this is a not too insane way to add git pre hooks f2d9781 |
I usually prefer not to include magic scripts to install things like git hooks. Instead I prefer to rely on documentation. I think you just add a check in the CI to make sure PRs complies to the style using uncrustify. Then is the developer's responsibility to fix it, and you can point to the docs to include uncrustify as a hook. |
Oki, i will look into adding a hook in Travis. So do you suggest not including the uncrustify formatting config file at all? Or just the install wrapper script which shouldn't be included? |
Created a development branch here, https://github.com/bokchan/libdrizzle-redux/tree/uncrustify |
The 2-space indentation is awful to look at, and makes it hard to understand the code flow. Since we own the repo now, it would be a good idea to adapt it to our style guide.
The text was updated successfully, but these errors were encountered: