You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Move phpcs command from library mode to binary mode
Until now we were using the phpcs in "library mode", i.e.
like it was a library and using its API to run it within
PHP. That had a few advantages but some problems, having
to "cheat" here and there to get everything working.
More noticeably, the include-paths and other details
were conflicting badly with the, now isolated and installed
by composer moodle-cs standard, and the phpcs.xml files now
present in core.
So this commit just changes that "unsupported" library use
by a more natural use as binary, so we just run it from shell,
with proper CLI options and so on.
The only detail a little bit tricky is that now, in order to
continue supporting the max-warnings option in moodle-plugin-ci,
instead of getting the number of errors and warnings from the API,
we have to generate the json report and extract totals information
from there. Anyway, it seems to be stable enough. Covered with tests.
Copy file name to clipboardExpand all lines: docs/CHANGELOG.md
+1-1Lines changed: 1 addition & 1 deletion
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -14,7 +14,7 @@ The format of this change log follows the advice given at [Keep a CHANGELOG](htt
14
14
- ACTION SUGGESTED: Ensure that the `pcov` or `xdebug` extensions are installed in your environment to get 'moodle-plugin-ci' using them automatically.
15
15
16
16
### Changed
17
-
- Switched from [local_codechecker]() to [moodle-cs]() for checking the coding style. Previously, `moodle-plugin-ci` (and other tools) required `local_codechecker` (that includes both `PHP_Codesniffer` and the `moodle` standard) to verify the coding style. Now, the `moodle` standard has been moved to be a standalone repository and all the tools will be using it and installing `PHP_Codesniffer` via composer. No changes in behavior are expected.
17
+
- Switched from [local_codechecker](https://github.com/moodlehq/moodle-local_codechecker) to [moodle-cs](https://github.com/moodlehq/moodle-cs) for checking the coding style. Previously, `moodle-plugin-ci` (and other tools) required `local_codechecker` (that includes both `PHP_Codesniffer` and the `moodle` standard) to verify the coding style. Now, the `moodle` standard has been moved to be a standalone repository and all the tools will be using it and installing `PHP_Codesniffer` via composer. No changes in behavior are expected.
0 commit comments