Skip to content

Commit

Permalink
Update readme.
Browse files Browse the repository at this point in the history
  • Loading branch information
ryanwelcher committed Jan 23, 2025
1 parent 5de574a commit 66f42b5
Show file tree
Hide file tree
Showing 2 changed files with 265 additions and 14 deletions.
27 changes: 13 additions & 14 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,21 +1,20 @@
# WordPress Code Examples Starter

This template repository is pre-configured to provide all of the tools to format code to match the WordPress coding standards.
# Newspack starter template for custom plugins

This template is a pre-configured starting point for custom plugin development on the Newspack platform.
It will give you all of the tools you needs to get up and running quickly.

## What does it provide?

1. Linting and formatting tools for PHP, JavaScript, CSS and package.json files.
2. A GitHub action to that runs linting on PRs and merged to trunk.
3. Build process provided by `@wordpress/scripts`
1. A pre-configured build process provided by the `@wordpress/scripts` package. This is the standard build process for WordPress. For more information on configuration and options, please see the [official documentation](https://developer.wordpress.org/block-editor/reference-guides/packages/packages-scripts/).
2. A PHP CodeSniffer configuration that will check your code against the coding standards that are recommended by the Newspack team.
3. A Prettier configuration for WordPress.
4. Linting tools for CSS, JS and PHP
5. A GitHub action to check that your commits and merges adhere to the correct coding standards
6. A GitHub action to automatically deploy your changes when merged to trunk. (See the Setup section for how to enable this feature)

## How do I use it?
1. Start by clicking the `Use this template` to use this as a starting point for your project.
2. Run `npm run setup` to install everything.
3. If using VSCode add the following to your settings.json
```json
"editor.codeActionsOnSave": {
"source.fixAll.eslint": true
},
```

1. Start by clicking the `Use this template` to use this as a starting point for your project.
2. In the Secrets and Variables->Actions under the Settings menu of the new repository. Create new `SFTP_USER` and `SFTP_PASSWORD` secrets and add the credentials provided by NewPack for each.
3. Checkout the repo locally and run `npm run setup` to install everything.
4. Start developing!
252 changes: 252 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

0 comments on commit 66f42b5

Please sign in to comment.