Skip to content

Instantly share code, notes, and snippets.

@wrseward
wrseward / pre-commit.sh
Last active September 22, 2017 15:03
git pre-commit hook for php-cs-fixer
#!/usr/bin/env bash
set -e
echo "php-cs-fixer start"
PHP_CS_FIXER="./vendor/bin/php-cs-fixer"
if [ -x $PHP_CS_FIXER ]; then
if git diff --cached --name-only --diff-filter=ACMRTUXB | grep -q '\.php$'; then

Keybase proof

I hereby claim:

  • I am wrseward on github.
  • I am wrseward (https://keybase.io/wrseward) on keybase.
  • I have a public key ASAXIQ9Y9bxMrL10VmlEMZuh3CcU_9vC-C6EHdAPfF9LQQo

To claim this, I am signing this object: