style: Add a git pre-commit hook
authorAndreas Sandberg <andreas.sandberg@arm.com>
Wed, 30 Mar 2016 14:33:29 +0000 (15:33 +0100)
committerAndreas Sandberg <andreas.sandberg@arm.com>
Wed, 30 Mar 2016 14:33:29 +0000 (15:33 +0100)
commit5f9c0f8a24784443355f9f6cb54946b96347ac4e
treea5f3b66f2a3d4b5d0a33e4749fbcf3093c61b264
parent22ff270b17f43dc65f0788fec04ca15fd0428ca4
style: Add a git pre-commit hook

Add a git pre-commit hook that verifies that files that are about to
be committed. Since git stages changes into an index and the index
contains the changes that will be committed, the style checker only
looks at the state of files in the index.

Signed-off-by: Andreas Sandberg <andreas.sandberg@arm.com>
Reviewed-by: Nikos Nikoleris <nikos.nikoleris@arm.com>
Reviewed-by: Curtis Dunham <curtis.dunham@arm.com>
Reviewed-by: Steve Reinhardt <steve.reinhardt@amd.com>
--HG--
extra : rebase_source : 22a028bf13524cba188bd7896a0304f4c14ffeeb
util/git-pre-commit.py [new file with mode: 0755]