Open gber opened 1 month ago
@gber Do you mind fixing the code-style issues (see CI output) too? :)
I did a quick review and it looks very good. Thanks for your good work :+1:
@gber Do you mind fixing the code-style issues (see CI output) too? :)
I don't quite understand the difference between phpcbf
and phpcs
, the former seems to do some automatic correction but shows far fewer errors:
> ./vendor/bin/phpcbf addons/ --extensions=inc --standard=PSR12
PHPCBF RESULT SUMMARY
----------------------------------------------------------------------
FILE FIXED REMAINING
----------------------------------------------------------------------
...ger/addons/schoolmanager/class_importteachers.inc 3 23
----------------------------------------------------------------------
A TOTAL OF 3 ERRORS WERE FIXED IN 1 FILE
----------------------------------------------------------------------
whereas phpcs
returns ~ 150 errors and countless warnings.
phpcs is quite verbose in our case. Not all errors are automatically fixable by phpcbf. E.g. stuff like not using camel case or missing visibility declaration for methods or variables.
phpcbf
is actually just there to check, if there are any wrong whitespaces or weird bracket placements, in my workflow.
My workflow:
$ composer install $ ./vendor/bin/phpcbf addons/ --extensions=inc --standard=PSR12 $ git diff
I've found some minor whitespace changes in: addons/schoolmanager/class_importteachers.inc
This is a port to the GOsa 2.8 plugin structure including templates for the default theme. It includes a number of fixes for functionality which is currently broken in master.