-
Notifications
You must be signed in to change notification settings - Fork 35
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
# Conflicts: # composer.json
- Loading branch information
Showing
20 changed files
with
324 additions
and
133 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
root = true | ||
|
||
[*] | ||
charset = utf-8 | ||
end_of_line = lf | ||
indent_size = 4 | ||
indent_style = space | ||
insert_final_newline = true | ||
trim_trailing_whitespace = true | ||
|
||
[wp-config.example,index.example] | ||
indent_style = tab | ||
|
||
[*.md] | ||
trim_trailing_whitespace = false |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,85 @@ | ||
# Contributing to WP Starter | ||
First, let us say: **thank you** to be here! :+1: | ||
|
||
--- | ||
|
||
|
||
|
||
## Did you find a bug? | ||
|
||
- **Do not open up a GitHub issue if the bug is a security vulnerability**, and instead contact [Giuseppe](https://github.com/gmazzap) directly via email. | ||
- Ensure the bug was not already reported by searching on GitHub under [issues](https://github.com/wecodemore/wpstarter/issues). | ||
- If you're unable to find an open issue addressing the problem, [open a new one](https://github.com/wecodemore/wpstarter/issues/new?template=bug_report.md). Be sure to include a title and clear description, as much relevant information as possible. Code samples and / or executable test cases demonstrating the bug are very welcome. | ||
- Use the bug report template to create the issue, providing all the information listed there. | ||
- If you'd like to write a fix yourself, **please wait first for some feedback on the issue**. Then follow guidelines below to write the code and submit a PR. | ||
|
||
|
||
|
||
## Would you like to add a new feature or change an existing one? | ||
|
||
- [Open an issue](https://github.com/wecodemore/wpstarter/issues/new?template=feature_request.md) clearly explaining what feature you want to add or change and why. | ||
- Use the feature request template to create the issue, providing all the information listed there. | ||
- If you offer to implement the change yourself, there will be more chances that the addition / change will land to WP Starter. But **please don't start writing code before you get a positive feedback**. | ||
|
||
|
||
|
||
--- | ||
|
||
|
||
|
||
## Guidelines | ||
|
||
### Code Style | ||
|
||
- For v2.* we use [PSR-1](https://www.php-fig.org/psr/psr-1/) and [PSR-2](https://www.php-fig.org/psr/psr-2/) code style; | ||
- For v3+ we use [Inpsyde PHP coding standars](https://github.com/inpsyde/php-coding-standards). | ||
|
||
By cloning the repository and running: | ||
|
||
```shell | ||
./vendor/bin/phpcs | ||
``` | ||
|
||
it is possible to check code is compliant via [PHPCS](https://github.com/squizlabs/PHP_CodeSniffer). | ||
|
||
Be sure to install Composer dependencies first. | ||
|
||
### Git | ||
|
||
Before write any code: | ||
|
||
- Ensure an issue exist describing the bug, the wanted change or the new feature. If not, [open one](https://github.com/wecodemore/wpstarter/issues/new/choose). | ||
|
||
- Create **a new branch** named after the target issue plus a one-or-two words description of the topic: | ||
|
||
|
||
```shell | ||
git checkout -b issue-123-something-important | ||
``` | ||
|
||
#### Commits | ||
|
||
Please make one commit _per change_. If you are afraid that you might end up with too many commits, you can [squash commits](https://github.com/servo/servo/wiki/Beginner's-guide-to-rebasing-and-squashing). | ||
|
||
Please, always write clear messages for your commits. A good message is succinct, but still clearly explains *why* the change has been made, more than *how*. | ||
|
||
The whole commit message is made of 2 or 3 parts: | ||
|
||
1. A summary, *mandatory*, 60 characters or less, used **only** to explain the changes. It should read well when read after the sentence *"If merged this commit will..."* | ||
2. A more detailed description, *optional*, used only if the 60 characters of the summary are not enough to explain changes well. | ||
3. A reference to the relevant issue(s), *mandatory*. | ||
|
||
The different parts can be added to the commit by using the `-m` option multiple times. For example: | ||
|
||
```bash | ||
git commit \ | ||
-m"Improve output messages of wp-config step" \ | ||
-m"Old message was not making clear if the step failed or not" \ | ||
-m"See #123" | ||
``` | ||
|
||
#### Pull Requests | ||
|
||
1. Always **file PRs against the `dev` branch**. Nothing goes to `master` without going to `dev` first. In case you did not do that, please [update your pull request](https://help.github.com/articles/changing-the-base-branch-of-a-pull-request/). | ||
1. If possible, include tests. We can always use more test coverage. | ||
1. Use the text on the PR with a description of the change made. There's no need to duplicate information from the issue, but please remember to link the issue in the PR text. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
--- | ||
name: Bug report | ||
about: Create a report to help us improve | ||
|
||
--- | ||
|
||
**Describe the bug** | ||
A clear and concise description of what the bug is. | ||
|
||
**To Reproduce** | ||
Steps to reproduce the behavior: | ||
1. Go to '...' | ||
2. Click on '....' | ||
3. Scroll down to '....' | ||
4. See error | ||
|
||
**Expected behavior** | ||
A clear and concise description of what you expected to happen. | ||
|
||
**System (please complete the following information):** | ||
- OS: [e.g. iOS] | ||
- Version [e.g. 22] | ||
|
||
**Additional context** | ||
Add any other context about the problem here. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
--- | ||
name: Contribute documentation | ||
about: Help us to keep documentation healty | ||
|
||
--- | ||
|
||
- Did you find typo, grammar issues, or do you think some wording in documentation needs improvement? | ||
- Did you think there's something relevant that is not documented? | ||
- Is there documentation parts that you found hard to follow or understand? | ||
|
||
**Contributions to documentation are very welcome!** | ||
|
||
If you can contribute to documentation, please just do it. If you spotted a mistake, there's no need to opne an issue. Just file the changes directly to master (for current version) or to the "main" branch of the next version, if your changes regards that. | ||
|
||
Otherwise, if you can't do changes yourself, please open an issue only if you think the issue is relevant, and avoid opening an issue for a single typo fix or a missing space or things like that. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,17 @@ | ||
--- | ||
name: Feature request | ||
about: Suggest an idea for this project | ||
|
||
--- | ||
|
||
**Is your feature request related to a problem? Please describe.** | ||
A clear and concise description of what the problem is. Ex. I'm always frustrated when [...] | ||
|
||
**Describe the solution you'd like** | ||
A clear and concise description of what you want to happen. | ||
|
||
**Describe alternatives you've considered** | ||
A clear and concise description of any alternative solutions or features you've considered. | ||
|
||
**Additional context** | ||
Add any other context or screenshots about the feature request here. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
## Description | ||
|
||
Please describe what you have changed or added | ||
|
||
## How has this been tested? | ||
Please describe in detail how you tested your changes. | ||
|
||
## Types of changes | ||
What types of changes does your code introduce? | ||
|
||
### Bug fixes (non-breaking change which fixes an issue) | ||
- ... | ||
### New feature (non-breaking change which adds functionality) | ||
- ... | ||
## Breaking change (fix or feature that break existing functionality) | ||
- ... | ||
|
||
## Issues | ||
Which issue(s) this PR is addressing? | ||
|
||
## Checklist: | ||
- [ ] My code is tested | ||
- [ ] My code follows the project code style | ||
- [ ] My code has documentation (for new features or changed behavior) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,13 @@ | ||
<?xml version="1.0"?> | ||
<ruleset name="WPStarter"> | ||
<description>The code standard for WPStarter package.</description> | ||
<file>wpstarter/src/</file> | ||
<arg value="sp"/> | ||
<arg name="extensions" value="php"/> | ||
<arg name="report" value="full"/> | ||
<arg name="report" value="summary"/> | ||
<arg name="report" value="source"/> | ||
<rule ref="PSR2"/> | ||
<rule ref="PHPCompatibility"/> | ||
<config name="testVersion" value="5.3-"/> | ||
</ruleset> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.