Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Hardcode the Drupal coding standard name #71

Closed
wants to merge 1 commit into from

Conversation

kostajh
Copy link

@kostajh kostajh commented Apr 19, 2016

If I do this, Drupal mode, flycheck and phpcs work happily together. If I don't, I get errors that Drupal and DrupalPractice coding standard not found, and if I manually remove the DrupalPractice code sniff style, I get Drupal and PSR1 coding standard not found.

If I do this, Drupal mode, flycheck and phpcs work happily together. If I don't, I get errors that `Drupal and DrupalPractice coding standard not found`, and if I manually remove the `DrupalPractice` code sniff style, I get `Drupal and PSR1 coding standard not found`.
@arnested
Copy link
Owner

What is the output of running phpcs -i in a shell?

@kostajh
Copy link
Author

kostajh commented Apr 19, 2016

The installed coding standards are MySource, PSR2, Zend, Squiz, PHPCS, PEAR, Drupal and PSR1

Arne Jørgensen writes:

What is the output of running phpcs -i in a shell?


You are receiving this because you authored the thread.
Reply to this email directly or view it on GitHub:
#71 (comment)

@kostajh | [email protected]

@kostajh
Copy link
Author

kostajh commented Apr 19, 2016

I'm on phpcs 2.6.0 btw

@arnested
Copy link
Owner

I'm on the same version and get The installed coding standards are MySource, PEAR, PHPCS, PSR1, PSR2, Squiz, Zend, ArneDrupal, Drupal, DrupalPractice, DrupalSecure, Symfony2 and Security.

That's not very different from you.

Merging your pull request could lead to wrong standards being (trying to be) used. But apparently I need to adjust the regex (maybe phpcs changed its output).

I'll look into this later today (gotta do some work now).

arnested added a commit that referenced this pull request Apr 20, 2016
@arnested arnested mentioned this pull request Apr 20, 2016
@arnested arnested closed this in #72 Apr 20, 2016
@arnested
Copy link
Owner

We couldn't catch the Drupal standard if it was the next to last standard as in:

The installed coding standards are MySource, PSR2, Zend, Squiz, PHPCS, PEAR, Drupal and PSR1

Maybe there used to be an Oxford comma in the output of phpcs? Or maybe we have always been failing on this.

Fixed in #72.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants