Join GitHub today
GitHub is home to over 36 million developers working together to host and review code, manage projects, and build software together.
Sign upAStyle usage for consistent code style #108
Conversation
etinquis
added some commits
Dec 19, 2011
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
etinquis commentedDec 19, 2011
AStyle info can be found at http://astyle.sourceforge.net/.
A sample of the changes it makes can be found at https://gist.github.com/1495012.
You can use the included pre-commit git hook in Tools/githooks/pre-commit by copying it into
%MONOCLEDIR%/.git/hooks/, which will automatically format the files you attempt to commit, you can format every .cpp/.h file in the tree by usingTools/AStyle/AStyle -r *.cpp *.h --options=Tools/AStyle/astylerc, or you can do what the githook does and do something similar to the following in windows:Needs to be tested on linux and mac.