Skip to content

Commit

Permalink
Update CONTRIBUTING.md (#19)
Browse files Browse the repository at this point in the history
  • Loading branch information
johncollinson2001 authored Oct 7, 2024
1 parent ae8b235 commit a856c9d
Showing 1 changed file with 13 additions and 31 deletions.
44 changes: 13 additions & 31 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -1,37 +1,19 @@
# Contribution Guidelines
# Contributing

Before you start contributing to the project, please read the following guidelines. We follow the below guidelines to contribute to this repository.
If you want to contribute to the project, raise a PR on GitHub.

## How To Contribute
We use pre-commit to run analysis and checks on the changes being committed. Take the following steps to ensure the pre-commit hook is installed and working:

* **DO** submit all changes via pull requests (PRs). They will be reviewed and potentially merged after a peer review from at least one maintainer.
* **DO** give PRs short but descriptive names.
* **DO** write a useful but brief description of what the PR is for.
* **DO** ensure each commit successfully builds. The entire PR must pass all checks before it will be merged.
* **DO** address PR feedback in additional commits instead of amending.
* **DO NOT** submit "work in progress" PRs. Please mark them as *Draft*. A PR should only be submitted when it is considered ready for review.
* **DO NOT** mix independent and unrelated changes in one PR.
* If there is a major upgrade or a feature addition to the project, it might be a good idea to get started with a Github issue or a Github discussion to discuss the feature or the upgrade before starting a PR on the upgrade.
1. Install git
* Ensure the git `bin` directory has been added to %PATH%: `C:\Program Files\Git\bin`

## Pull Requests
1. Install Python
* Ensure the python `bin` directory has been added to %PATH%

We use pull requests to review and merge code into the `main` branch.
1. Install pre-commit
* Open a terminal and navigate to the repository root directory
* Install pre-commit with the following command: `pip install pre-commit`
* Install pre-commit within the repository with the following command: `pre-commit install`
* Run `pre-commit run --all-files` to check pre-commit is working

Please follow the steps below to create a pull request:

1. Fork the repository from the `main` branch ( Refer steps to [create a fork](https://docs.github.com/en/pull-requests/collaborating-with-pull-requests/working-with-forks/fork-a-repo)). We use `main` branch only for sync'ing forks. All development contributions should be made to the `development` branch.

1. Create a new branch (example `development`) in your forked repository for your feature or bug fix. Detailed branching and development strategy is outline in [this guide](docs/setup-guide.md#diagram-for-forking-and-syncing).

1. Make sure the pre-commit hook is installed and working:
1. Install pre-commit using this [link](https://pre-commit.com/#installation)
1. Run `pre-commit run --all-files` from the root of the repository.
1. Follow [these](https://github.com/pocc/pre-commit-hooks?tab=readme-ov-file#information-about-the-commands) instructions to install the commands

1. Run tests, linters and checks locally and make sure the pipeline is passing

1. Make sure the pipeline is passing

1. Make sure you have each PR reviewed

1. Once the PR is approved, merge it to the `main` branch, preferably using `Squash and Merge`
> For full details [see this link](https://pre-commit.com/#installation)

0 comments on commit a856c9d

Please sign in to comment.