Skip to content

Conversation

@ggwicz
Copy link
Contributor

@ggwicz ggwicz commented Jan 15, 2024

Summary

  • Adds automattic/vipwpcs dependency so that WordPress-VIP-Go ruleset becomes available when wanted.
  • Renames TEC/ dir to StellarWP/
  • Re-establishes symlinks so TEC and TribalScents now both point to StellarWP/

Example phpcs.xml

Here's an example phpcs.xml file I tested with locally. It's the same one found in TEC, but notice the use of <rule ref="StellarWP"/> instead of <rule ref="TEC"/>:

<?xml version="1.0"?>
<ruleset name="StellarWP Coding Standards">
	<rule ref="WordPress-VIP-Go"/>
	<rule ref="WordPress-Docs">
		<exclude-pattern>*/tests/*</exclude-pattern>
	</rule>
	<rule ref="WordPress">
		<exclude name="WordPress.Files.FileName"/>
		<exclude name="Generic.Arrays.DisallowShortArraySyntax"/>
	</rule>
	<rule ref="StellarWP"/>

	<!--exclude the rule for violation of direct DB calls as some have no alternative-->
	<rule ref="WordPress.DB.DirectDatabaseQuery">
		<exclude-pattern>src/Test.php</exclude-pattern>
	</rule>

	<exclude-pattern>*/tests/_support/_generated/*</exclude-pattern>
	<exclude-pattern>*/vendor/*</exclude-pattern>
</ruleset>

@ggwicz ggwicz self-assigned this Jan 15, 2024
@ggwicz ggwicz marked this pull request as ready for review January 15, 2024 19:53
@ggwicz ggwicz requested review from Camwyn, bordoni and borkweb January 15, 2024 19:53
@Camwyn Camwyn merged commit 9343d73 into main Jan 17, 2024
@Camwyn Camwyn deleted the feat/genericize-standards-for-stellar branch January 17, 2024 23:01
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.

4 participants