Commit Graph
2 Commits
Author SHA1 Message Date
Patrick Fallberg 6564daec3e Update the pre-commit git hook (#667)
It now supports both Linux and Windows and checks
both coding style (astyle) and does static code
analysis (cppcheck).
Tested using "Bash on Ubuntu on Windows" and the
git shell (via GitHub for Windows).

Installation is done by executing hooks/install-hooks.sh
Windows users has to execute it in a cygwin based git shell.

Tools:
astyle (2.05.1 or newer)
cppcheck (1.76.1 or newer)
2016-11-28 14:57:26 -08:00
Patrick Fallberg 45b671457d Coding style related changes (#653)
* Add .astylerc with the core coding standard

* Added pre-commit git hook

The hook currently only checks code format using
astyle and will not permit commits which cause
astyle to change the contents of any source file
in the commit.
This is useful to have automatic coding standard
verification done without having to wait for
Jenkins to react to a pull request.

Installation:
Linux:
ln -s ../../tools/hooks/pre-commit.sh .git/hooks/pre-commit
Windows:
copy tools\hooks\pre-commit.sh .git\hooks\pre-commit

* Added editorconfig and updated gitattributes

Unix style line endings are now default.

* Resolved doxygen warning
2016-11-24 16:43:04 +01:00