Workflow
Complete workflow for day-to-day WordPress development.
Setting up local dev env
Depending on OS, dev tools to be installed locally.
Start a new project
Be it WordPress theme or plugin, free or paid, we will be using a git repo.
- For public project, github.com is good
- For private project, you can use paid account on github.com or use gitlab.com
No matter where you host your git repo, on local you will be doing:
- git clone git://remote-path local-dir
- cd local-dir
- atom . #launch editor
TODO - for new project
- plugin or theme folder structure
- grunt task setup
- scaffolding
- composer
Test Driven Development
- Write test cases
- Write code that meets those test cases
- Run test cases
- git commit
- git push
TODO
npm version
alternative for git. Something likegit version minor|major|patch
.- git hooks to run test on
git commit
and/orgit push
Code Checks
- Coding Standard - phpcs, jshint, css, etc
- Code Quality - phpmd, copy-paste detector, etc
- Unit test cases - phpunit, js (not sure)
- Functional testing (e2e - end to end tetsing) - using selenium + nightwatch, etc
Continuous Integration
- build script (testing)
- deploy script (cleanup, packaging, delivery, publish)