sirbrillig / phpcs-changed

🐘 Run phpcs on files and only report new warnings/errors compared to the previous version.
MIT License
31 stars 11 forks source link

Handle empty vcs files #6

Closed sirbrillig closed 5 years ago

sirbrillig commented 5 years ago

When a newly added file is empty, then the command cat filename.php | phpcs fails with the error You must supply at least one file or directory to process. In that case, however, we know there are no phpcs errors so we can just skip that command.

Fixes #5