What are the Slack Archives?
It’s a history of our time together in the Slack Community! There’s a ton of knowledge in here, so feel free to search through the archives for a possible answer to your question.
Because this space is not active, you won’t be able to create a new post or comment here. If you have a question or want to start a discussion about something, head over to our categories and pick one to post in! You can always refer back to a post from Slack Archives if needed; just copy the link to use it as a reference..
I'm using spryker/code-sniffer 0.16.5 and want to disable the DocBlockConstSniff. I added this to th
I'm using spryker/code-sniffer 0.16.5 and want to disable the DocBlockConstSniff. I added this to the ruleset.xml, but it doesn't work.
<rule ref="vendor/spryker/code-sniffer/Spryker/Sniffs"> <exclude name="vendor/spryker/code-sniffer/Spryker/Sniffs/Commenting/DocBlockConstSniff.php"/> </rule>
Code sniffer still complains about Doc Block for const missing
. Did anybody manage to successfully disable specific sniffs?
Comments
-
Name needs to be the name and not the path.
For example:
<rule ref="vendor/spryker/code-sniffer/Spryker/ruleset.xml"> <exclude name="Spryker.Commenting.FileDocBlock" /> </rule>
0 -
Try something like this:
<rule ref="SlevomatCodingStandard.TypeHints"> <exclude name="SlevomatCodingStandard.TypeHints.DeclareStrictTypes"></exclude> <exclude name="SlevomatCodingStandard.TypeHints.DisallowArrayTypeHintSyntax"></exclude> <exclude name="SlevomatCodingStandard.TypeHints.DisallowMixedTypeHint"></exclude> <exclude name="SlevomatCodingStandard.TypeHints.LongTypeHints"></exclude> <exclude name="SlevomatCodingStandard.TypeHints.TypeHintDeclaration"></exclude> <exclude name="SlevomatCodingStandard.TypeHints.UselessConstantTypeHint"></exclude> </rule>
0 -
Thanks guys, will give it a try.
I sticked to the documentation so far, which seems to be wrong then: https://documentation.spryker.com/docs/updating-a-spryker-based-project
0 -
Got it, this one is working:
<rule ref="vendor/spryker/code-sniffer/Spryker/ruleset.xml"> <exclude name="Spryker.Commenting.DocBlockConst" /> </rule>
0 -
Yeah, someone who didn't try this wrote those docs
I provided a fix as PR: https://github.com/spryker/documentation/pull/348/files
Always also otherwise refer to the actual repo docs (README), as those are more likely to be fully in sync with the actual implementation.0 -
@UQK3ZPJEN Thanks for the quick response again.
Regarding the online docs I'd appreciate if it would be kept up to date regularly. Imho it doesn't make sense to have an online documentation that is not reliable.
0
Categories
- All Categories
- 42 Getting Started & Guidelines
- 7 Getting Started in the Community
- 8 Additional Resources
- 7 Community Ideas and Feedback
- 69 Spryker News
- 896 Developer Corner
- 758 Spryker Development
- 83 Spryker Dev Environment
- 361 Spryker Releases
- 3 Oryx frontend framework
- 34 Propel ORM
- 68 Community Projects
- 3 Community Ideation Board
- 30 Hackathon
- 3 PHP Bridge
- 6 Gacela Project
- 23 Job Opportunities
- 3.2K 📜 Slack Archives
- 116 Academy
- 5 Business Users
- 370 Docker
- 551 Slack General
- 2K Help
- 75 Knowledge Sharing
- 6 Random Stuff
- 4 Code Testing
- 32 Product & Business Questions
- 68 Spryker Safari Questions
- 50 Random