GitHub project link: https://github.com/rawsta/raw-child/. forked from https://github.com/studiopress/genesis-sample
heavily inspired by:
This is mainly my own Starter-theme for Genesis-based Websites but everyone is welcome to use it. It doesn't stray to far away from the original genesis-sample and is more a compilation of the usual tweaks and setup steps i tend to use on new projects.
Feedback always appreciated.
- Upload the Raw Child theme folder via FTP to your wp-content/themes/ directory. (The Genesis parent theme needs to be in the wp-content/themes/ directory as well.)
- Go to your WordPress dashboard and select Appearance.
- Activate the Raw Child theme.
- Inside your WordPress dashboard, go to Genesis > Theme Settings and configure them to your liking.
The version of Raw Child on GitHub includes tooling to check code against WordPress standards. To use it:
- Install Composer globally on your development machine. See Composer setup steps.
- In the command line, change directory to the Raw Child folder.
- Type the command
composer installto install PHP development dependencies. - Type
composer phpcsto run coding standards checks.
You'll see output highlighting issues with PHP files that do not conform to Raw Child coding standards.
Run composer phpcbf if you see “phpcbf can fix the x marked sniff violations automatically” in the output of composer phpcs.
Scripts are also provided to help with CSS linting, CSS autoprefixing, and creation of pot language files. To use them:
- Install Node.js, which also gives you the Node Package Manager (npm).
- In the command line, change directory to the Raw Child folder.
- Type the command
npm installto install dependencies.
You can then type any of these commands:
npm run autoprefixerto add and remove vendor prefixes instyle.css.npm run makepotto regenerate thelanguages/raw-child.potfile.npm run lint:cssto generate a report of style violations forstyle.css.npm run lint:jsto generate a report of style violations for JavaScript files.npm run fix:jsto fix any JavaScript style violations that can be corrected automatically.npm run zipto create a raw-child.zip. Files in theexcludesarray inscripts/makezip.jsare omitted.genesis-theme-claimchange the child-theme claim and title genesis-theme-claim.
- Follow the install instructions for npm scripts above.
- Switch to the git branch you plan to distribute.
- Bump version numbers manually and commit those changes.
- Type
npm run zipto createraw-child.zip. Files in theexcludesarray inscripts/makezip.jsare omitted from the zip.filename.mdfiles will be renamed tofilename.txt.