Dolibarr / dolibarr

Dolibarr ERP CRM is a modern software package to manage your company or foundation's activity (contacts, suppliers, invoices, orders, stocks, agenda, accounting, ...). it's an open source Web application (written in PHP) designed for businesses of any sizes, foundations and freelancers.
https://www.dolibarr.org
GNU General Public License v3.0
5.2k stars 2.71k forks source link

PHPCS forcing `Generic.WhiteSpace.DisallowTabIndent.TabsUsed` #23596

Closed Daviid-P closed 7 months ago

Daviid-P commented 1 year ago

Bug

My pre-commit hook keeps showing me the error

 3945 | ERROR   | [x] Spaces must be used to indent lines; tabs are
      |         |     not allowed
      |         |     (Generic.WhiteSpace.DisallowTabIndent.TabsUsed)

Doesn't this rule mean that tabs are OK?

<!-- Disallow usage of space -->
<rule ref="Generic.WhiteSpace.DisallowSpaceIndent.SpacesUsed" />

After phpcs and phpcbf finish running I get a lot of files modified because tabs have been changed to spaces.

${DIRPHPCS}phpcs -s -p -d memory_limit=-1 --parallel=2 --extensions=php --colors --tab-width=4 --standard=C:/xampp7/htdocs/Dolibarr16.0.3/dev/setup/codesniffer/ruleset.xml --encoding=utf-8 --runtime-set ignore_warnings_on_exit true $FILES

Just in case I've also tried:

github-actions[bot] commented 7 months ago

This issue is stale because it has been open 1 year with no activity. If this is a bug, please comment to confirm it is still present on latest stable version. if this is a feature request, please comment to notify the request is still relevant and not yet covered by latest stable version. This issue may be closed automatically by stale bot in 10 days (you should still be able to re-open it if required).