This is the master Wordpress theme for Greenpeace Planet4 project. You can learn more about this project on the planet4 blog.
This theme is based on the timber/starter-theme
codebase.
It has a correlated child theme.
You can use the theme in Wordpress directly, by including it at your composer.json
file:
"require": {
...
"greenpeace/planet4-master-theme" : "X.X.X",
"greenpeace/planet4-child-theme" : "X.X.X",
...
},
By default the child theme is used but you can activate the master theme
by specifying it in wp-cli.yml
like:
theme activate:
- planet4-master-theme
You can then run composer run-script theme:activate
to activate it.
We use gulp as automation tools for local development.
Available tasks
gulp sass
'concatanates/compiles sass files into a minified single stylesheet'gulp uglify
'concatanates/mangles js files into a minified single js file'gulp watch
'watches for changes in js or sccs and runs the minification tasks'gulp git_hooks
'copies repo's git hooks to local git repo'
We follow the WordPress Coding Standards
We use a custom php codesniffer ruleset which adds some rules over WordPress-Core, WordPress-Docs and WordPress-Extra rulesets.
WordPress Coding Standards Rulesets
WordPress Coding Standards Wiki
To run the php codesniffer
$ vendor/bin/phpcs
or
$ composer sniffs
To run the php code beautifier and fixer
$ vendor/bin/phpcbf
or
$ composer fixes
Please read the Contribution Guidelines for Planet4.
Automated tests done using BrowserStack.