Skip to content

Commit 3d226eb

Browse files
authored
Update action.yml PHPCBF_EXIT_CODE
1 parent dbda4c8 commit 3d226eb

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

action.yml

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -108,12 +108,14 @@ runs:
108108
if: env.HAS_ISSUES == 'true'
109109
run: |
110110
echo "phpcbf standard=${{ env.USE_STANDARD }}"
111-
vendor/bin/phpcbf --extensions="${{ inputs.extensions }}" . --standard="${{ env.USE_STANDARD }}" --ignore="${{ inputs.ignore }}" || MORE_ISSUES=true
112-
: "${MORE_ISSUES:=false}"
113-
if [ "${MORE_ISSUES}" = "true" ]; then
111+
PHPCBF_EXIT_CODE=0
112+
vendor/bin/phpcbf --extensions="${{ inputs.extensions }}" . --standard="${{ env.USE_STANDARD }}" --ignore="${{ inputs.ignore }}" || PHPCBF_EXIT_CODE=$?
113+
##: "${MORE_ISSUES:=false}"
114+
if [ ${PHPCBF_EXIT_CODE} -ne 0 ]; then
115+
##if [ "${MORE_ISSUES}" = "true" ]; then
114116
#echo "::warning title=Some phpcs issues remained::Manual fix necessary. Compare to the PHP Code Sniffer section above."
115117
# todo investigate when this happens
116-
echo "::warning title=Non-zero code exit of phpcbf::Manual fix necessary?"
118+
echo "::warning title=Non-zero code exit of phpcbf ${PHPCBF_EXIT_CODE}::Manual fix necessary?"
117119
fi
118120
119121
# restore composer.json before staging the changes

0 commit comments

Comments
 (0)