Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/oefenweb/wordpress-codesniffer

Modified version of the Wordpress Code Sniffer
https://github.com/oefenweb/wordpress-codesniffer

codesniffer phpcs sniffer wordpress

Last synced: 30 days ago
JSON representation

Modified version of the Wordpress Code Sniffer

Awesome Lists containing this project

README

        

# Oefenweb Code Sniffer for Wordpress

This code works with [phpcs](https://github.com/squizlabs/PHP_CodeSniffer) and checks code against the coding standards used at Oefenweb.

## Installation

It's generally recommended to install these code sniffs with `composer`:

```sh
mkdir WordpressOefenweb && cd $_ && composer require oefenweb/wordpress-codesniffer=dev-master;
```

```sh
vendor/bin/phpcs \
--config-set installed_paths "${PWD}/vendor/wp-coding-standards/wpcs,${PWD}/vendor/oefenweb/wordpress-codesniffer" \
;
```

This lets `phpcs` know where to find your new sniffs. Ensure that you do not overwrite any existing `installed_paths` value.

## Usage

```sh
vendor/bin/phpcs --standard=WordpressOefenweb ~/foo/bar/wp-load.php;
```