style: Add a git pre-commit hook
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

rjschof/gem5,gedare/gem5,KuroeKurose/gem5,Weil0ng/gem5,aclifton/cpeg853-gem5,SanchayanMaity/gem5,TUD-OS/gem5-dtu,gedare/gem5,SanchayanMaity/gem5,HwisooSo/gemV-update,SanchayanMaity/gem5,SanchayanMaity/gem5,gem5/gem5,HwisooSo/gemV-update,powerjg/gem5-ci-test,sobercoder/gem5,rallylee/gem5,qizenguf/MLC-STT,rallylee/gem5,briancoutinho0905/2dsampling,TUD-OS/gem5-dtu,gem5/gem5,briancoutinho0905/2dsampling,gedare/gem5,gem5/gem5,sobercoder/gem5,aclifton/cpeg853-gem5,gem5/gem5,aclifton/cpeg853-gem5,TUD-OS/gem5-dtu,aclifton/cpeg853-gem5,Weil0ng/gem5,qizenguf/MLC-STT,briancoutinho0905/2dsampling,Weil0ng/gem5,powerjg/gem5-ci-test,Weil0ng/gem5,qizenguf/MLC-STT,SanchayanMaity/gem5,KuroeKurose/gem5,powerjg/gem5-ci-test,KuroeKurose/gem5,KuroeKurose/gem5,Weil0ng/gem5,powerjg/gem5-ci-test,cancro7/gem5,cancro7/gem5,gem5/gem5,sobercoder/gem5,briancoutinho0905/2dsampling,HwisooSo/gemV-update,aclifton/cpeg853-gem5,powerjg/gem5-ci-test,KuroeKurose/gem5,gem5/gem5,qizenguf/MLC-STT,aclifton/cpeg853-gem5,qizenguf/MLC-STT,rallylee/gem5,TUD-OS/gem5-dtu,rallylee/gem5,rjschof/gem5,Weil0ng/gem5,Weil0ng/gem5,HwisooSo/gemV-update,gedare/gem5,rjschof/gem5,cancro7/gem5,briancoutinho0905/2dsampling,sobercoder/gem5,rallylee/gem5,sobercoder/gem5,briancoutinho0905/2dsampling,KuroeKurose/gem5,rjschof/gem5,gedare/gem5,rallylee/gem5,sobercoder/gem5,KuroeKurose/gem5,gedare/gem5,qizenguf/MLC-STT,TUD-OS/gem5-dtu,gem5/gem5,cancro7/gem5,powerjg/gem5-ci-test,gedare/gem5,aclifton/cpeg853-gem5,cancro7/gem5,rallylee/gem5,HwisooSo/gemV-update,sobercoder/gem5,rjschof/gem5,TUD-OS/gem5-dtu,qizenguf/MLC-STT,TUD-OS/gem5-dtu,briancoutinho0905/2dsampling,HwisooSo/gemV-update,rjschof/gem5,cancro7/gem5,SanchayanMaity/gem5,powerjg/gem5-ci-test,cancro7/gem5,SanchayanMaity/gem5,rjschof/gem5,HwisooSo/gemV-update