Skip to content
This repository has been archived by the owner on Jan 21, 2020. It is now read-only.

PSR-12 ruleset #22

Merged
merged 20 commits into from Nov 5, 2019
Merged

PSR-12 ruleset #22

merged 20 commits into from Nov 5, 2019

Conversation

geerteltink
Copy link
Member

@geerteltink geerteltink commented Oct 17, 2019

This PR updates dependencies, uses PSR-12 as the base ruleset and refactors the ruleset and test into the PSR-12 documentation format. Some rules had to be left out or replaced as they conflict with the PSR-12 base ruleset.

  • Update dependencies
  • Import additional rules
  • Import array rules
  • Import string rules
  • Import phpdoc and commenting rules
  • Update docs
  • Update to phpcs 3.5.1

resolves #18
resolves #19

@geerteltink geerteltink self-assigned this Oct 17, 2019
@geerteltink geerteltink changed the title Feature/psr 12 PSR-12 ruleset Oct 17, 2019
@geerteltink geerteltink added this to the 2.0.0 milestone Oct 17, 2019
@geerteltink geerteltink added this to In progress in Zend Coding Standard 2 via automation Oct 17, 2019
@weierophinney
Copy link
Member

Ping me when you've finished the todo items, as I'd love to review this!

@geerteltink
Copy link
Member Author

@weierophinney and @webimpress PR is ready for review.

Copy link
Member

@froschdesign froschdesign left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

My review is related to the update of the documentation.

The following problems occur repeatedly:

  • the name of the framework is written with space: "Zend Framework"
  • for code examples please use always 3 backticks
  • for hints in blockquotes please use a headline with the third order as first headline. (> ### …)

I think all these problems can be fixed per search and replace.

docs/book/v2/coding-style-guide.md Outdated Show resolved Hide resolved
docs/book/v2/coding-style-guide.md Outdated Show resolved Hide resolved
docs/book/v2/coding-style-guide.md Outdated Show resolved Hide resolved
docs/book/v2/coding-style-guide.md Outdated Show resolved Hide resolved
docs/book/v2/coding-style-guide.md Outdated Show resolved Hide resolved
docs/book/v2/coding-style-guide.md Outdated Show resolved Hide resolved
Zend Coding Standard 2 automation moved this from In progress to Needs review Oct 18, 2019
Copy link
Member

@weierophinney weierophinney left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Left a ton of code suggestions, mostly around proper usage of RFC 2119 verbiage (mostly, I suggest using MUST in place of MAY, as most of the time, these are required rules).

Also noted a few questions around some of the rules that I feel either need clarification, or I need links to discussions about.

src/ZendCodingStandard/ruleset.xml Show resolved Hide resolved
src/ZendCodingStandard/ruleset.xml Show resolved Hide resolved
src/ZendCodingStandard/ruleset.xml Outdated Show resolved Hide resolved
src/ZendCodingStandard/ruleset.xml Outdated Show resolved Hide resolved
src/ZendCodingStandard/ruleset.xml Outdated Show resolved Hide resolved
src/ZendCodingStandard/ruleset.xml Outdated Show resolved Hide resolved
src/ZendCodingStandard/ruleset.xml Outdated Show resolved Hide resolved
src/ZendCodingStandard/ruleset.xml Outdated Show resolved Hide resolved
src/ZendCodingStandard/ruleset.xml Outdated Show resolved Hide resolved
src/ZendCodingStandard/ruleset.xml Outdated Show resolved Hide resolved
@geerteltink
Copy link
Member Author

@weierophinney applied changes as requested, waiting for #22 (comment) and #22 (comment).

@geerteltink geerteltink merged commit e6201f3 into zendframework:develop Nov 5, 2019
Zend Coding Standard 2 automation moved this from Needs review to Done Nov 5, 2019
@geerteltink geerteltink deleted the feature/psr-12 branch November 5, 2019 16:01
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
Development

Successfully merging this pull request may close these issues.

None yet

4 participants