aboutsummaryrefslogtreecommitdiff
path: root/bin/phpcsff.mi5
blob: 5e33f047e6f551151db059226969e9391c7b6a8c (plain) (blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
# Use php-cs-fixer as a source filter.
self=phpcsff

<%
include(`include/mktd.m4')
%>

# Duplicate stdin into a file
if ! command -v php-cs-fixer >/dev/null 2>&1 ; then
    printf >&2 'php-cs-fixer: command not found\n'
    exit 1
fi
cat -- "${@:--}" > "$td"/src.php
php-cs-fixer fix --quiet -- "$td"/src.php
cat -- "$td"/src.php