maltzj / google-style-precommit-hook

A pre-commit hook which will automatically format your code with google's codestyle guidelines!
56 stars 72 forks source link

Use the list of files supplied by pre-commit #17

Open navaneeth-spotnana opened 4 years ago

navaneeth-spotnana commented 4 years ago

pre-commit passes a list of files according the exclusion and other rules to the script. Currently format-code.sh doesn't respect the list, and creates its own list of files.

This was leading to unwanted files getting formatted, for example, when merging.