Improvements to the contribution guide

This commit is contained in:
Luke Towers 2021-02-21 09:57:42 -06:00 committed by GitHub
parent 6a9e60dd49
commit e3cf0e5843
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 21 additions and 19 deletions

View File

@ -1,6 +1,6 @@
# Contributing to OctoberCMS
Thank you for your interest in contributing to the OctoberCMS project. We appreciate any assistance that community members and users of OctoberCMS are willing to provide. You can contribute to the project in several different ways:
Thank you for your interest in contributing to the October CMS project. We appreciate any assistance that community members and users of October CMS are willing to provide. You can contribute to the project in several different ways:
- [Reporting a Security Vulnerability](#reporting-a-security-vulnerability)
- [Reporting an issue with OctoberCMS](#reporting-an-issue-with-octobercms)
@ -13,9 +13,9 @@ Thank you for your interest in contributing to the OctoberCMS project. We apprec
Please review [our security policy](https://github.com/octobercms/october/security/policy) on how to report security vulnerabilities. Please do not report security vulnerabilities on GitHub.
## Reporting an issue with OctoberCMS
## Reporting an issue with October CMS
>**NOTE:** If your issue is related to an OctoberCMS plugin, please see the [Reporting an issue with an OctoberCMS plugin](#reporting-an-issue-with-an-octobercms-plugin) section below.
>**NOTE:** If your issue is related to an October CMS plugin, please see the [Reporting an issue with an October CMS plugin](#reporting-an-issue-with-an-octobercms-plugin) section below.
We work hard to process bugs that are reported, to assist with this please ensure the following details are always included:
@ -25,7 +25,7 @@ We work hard to process bugs that are reported, to assist with this please ensur
- **Reproduce steps**: Clearly mention the steps to reproduce the bug.
- **Expected behavior**: Describe how OctoberCMS should behave on above mentioned steps.
- **Expected behavior**: Describe how October CMS should behave on above mentioned steps.
- **Actual behavior**: What is the actual result on running above steps i.e. the bug behavior - **include any error messages**.
@ -47,7 +47,7 @@ If possible, please provide any screenshots or GIFs of the issue occurring to pr
If you find out your bug is actually a duplicate of another bug and only notice that after you created it, please also close your bug with a short reference to the other issue that was there before.
#### Reporting an issue with an OctoberCMS plugin
#### Reporting an issue with an October CMS plugin
>Please don't use the main GitHub for reporting issues with plugins.
@ -57,11 +57,11 @@ If you are unable to contact the plugin author and the issue prevents the plugin
#### Escalation process
We do our best to attend to all reported issues. If you have an important issue that requires attention, consider submitting a bounty using the [OctoberCMS Bounty Program](https://www.bountysource.com/teams/october).
We do our best to attend to all reported issues. If you have an important issue that requires attention, consider submitting a bounty using the [October CMS Bounty Program](https://www.bountysource.com/teams/october).
## Making a Feature Request
>**NOTE:** Please don't use GitHub issues for suggesting a new feature. If you have a feature idea, the best place to suggest it is the [OctoberCMS website forum](https://octobercms.com/forum/chan/feature-requests).
>**NOTE:** Please don't use GitHub issues for suggesting a new feature. If you have a feature idea, the best place to suggest it is the [October CMS website forum](https://octobercms.com/forum/chan/feature-requests).
Only use GitHub if you are planning on contributing a new feature and developing it. If you want to discuss your idea first, before "officially" posting it anywhere, you can always join us on [Discord](https://discord.gg/gEKgwSZ).
@ -86,9 +86,9 @@ Thank you for your contributions!
#### Best practices
It is ideal to keep your development branch or fork synchronised with the core OctoberCMS `develop` branch when submitting Pull Requests, as this minimises the possibility of merge conflicts.
It is ideal to keep your development branch or fork synchronised with the core October CMS `develop` branch when submitting Pull Requests, as this minimises the possibility of merge conflicts.
To keep in sync with OctoberCMS, add the core OctoberCMS repository as a Git remote (ie. `upstream`) and pull changes from the OctoberCMS repository into your local `develop` branch as often as possible:
To keep in sync with October CMS, add the core OctoberCMS repository as a Git remote (ie. `upstream`) and pull changes from the OctoberCMS repository into your local `develop` branch as often as possible:
```
git remote add upstream git@github.com:octobercms/october.git
@ -97,7 +97,7 @@ git checkout develop
git pull upstream develop
```
This ensures that your local `develop` branch matches OctoberCMS. When developing a pull request, it is best to use your own development branch. For example, creating a fix to improve spelling on a language file could be made into a branch called `lang-en-spelling-fixes`, which can be branched off from the `develop` branch.
This ensures that your local `develop` branch matches October CMS. When developing a pull request, it is best to use your own development branch. For example, creating a fix to improve spelling on a language file could be made into a branch called `lang-en-spelling-fixes`, which can be branched off from the `develop` branch.
```
git checkout -b lang-en-spelling-fixes develop
@ -109,15 +109,15 @@ When you wish to update your development branch with the latest changes from the
git merge develop
```
This will merge all the latest changes from the OctoberCMS `develop` branch into your development branch.
This will merge all the latest changes from the October CMS `develop` branch into your development branch.
#### Resolving merge conflicts
Occassionally, you may encounter a merge conflict with your Pull Request. This most commonly occurs if another change made to the OctoberCMS repository was made to a file that your Pull Request has also changed.
Occassionally, you may encounter a merge conflict with your Pull Request. This most commonly occurs if another change made to the October CMS repository was made to a file that your Pull Request has also changed.
It is the responsibility of the author of the Pull Request to resolve any merge conflicts before their Pull Request is accepted.
You should ensure that your local copy of OctoberCMS is synchronised with with the `develop` branch in the OctoberCMS repository. Please follow the [steps above](#best-practices) to synchronise the repositories.
You should ensure that your local copy of October CMS is synchronised with with the `develop` branch in the October CMS repository. Please follow the [steps above](#best-practices) to synchronise the repositories.
If Git reports that your changes have conflicts, you will need to resolve the changes in a way that includes the changes from the OctoberCMS repository as well as implementing your Pull Request's changes. See GitHub's guide to [resolving a merge conflict](https://help.github.com/en/articles/resolving-a-merge-conflict-using-the-command-line) for tips on resolving conflicts.
@ -133,24 +133,26 @@ To validate your changes against our coding standards, you may run `./vendor/bin
#### Team rules
The OctoberCMS team follows the [developer guidelines](https://octobercms.com/docs/help/developer-guide) as much as possible.
The October CMS team follows the [developer guidelines](https://octobercms.com/docs/help/developer-guide) as much as possible.
## Testing a Pull Request
Although we aim to test all pull requests made to the OctoberCMS repository, the maintainers of OctoberCMS are volunteers and may not be able to promptly attend to all pull requests.
Although we aim to test all pull requests made to the October CMS repository, the maintainers of October CMS are volunteers and may not be able to promptly attend to all pull requests.
To help speed things up, any assistance with testing Pull Requests and fixes will be very appreciated. The best Pull Requests to test are those that are tagged as [**Testing Needed**](https://github.com/octobercms/october/pulls?q=is%3Apr+is%3Aopen+label%3A%22Testing+Needed%22) in the repository.
To test a Pull Request, you can use the steps below in a terminal or command-line interface to create a fresh installation of OctoberCMS with the changes made in the Pull Request, ready to test. In this example, we have a user called `qwerty123` that has created a pull request with an ID of `#4509`.
To test a Pull Request, you can use the steps below in a terminal or command-line interface to create a fresh installation of October CMS with the changes made in the Pull Request, ready to test. In this example, we have a user called `qwerty123` that has created a pull request with an ID of `#4509`.
1. Check out a copy of the OctoberCMS repository to a folder that you can view in your web browser: `git clone git@github.com:octobercms/october.git`. This will add the files into a subfolder called `october`.
1. Check out a copy of the October CMS repository to a folder that you can view in your web browser: `git clone git@github.com:octobercms/october.git`. This will add the files into a subfolder called `october`.
2. Then, go to the `october` subfolder and check out **@qwerty123**'s changes in a branch in your local repository: `git fetch origin pull/4509/head:pr-4509`. This will pull their changes into a branch called `pr-4509`. You will then need to check out the branch: `git checkout pr-4509`.
3. Next, get the Composer dependencies: `composer update`.
4. Next, run `php artisan october:env` to create a `.env` file in your folder. This will contain the configuration values for the database and site.
4. Next run `git checkout pr-4509` again in case composer overwrote the changes.
5. Finally, once you've populated that file with your database and site details, run `php artisan october:up` to install the necessary database tables.
5. Next, run `php artisan october:env` to create a `.env` file in your folder. This will contain the configuration values for the database and site.
6. Finally, once you've populated that file with your database and site details, run `php artisan october:up` to install the necessary database tables.
At this point, you should have a working copy of the Pull Request ready to test.