Skip to content

Commit

Permalink
Update CONTRIBUTING.md
Browse files Browse the repository at this point in the history
  • Loading branch information
aivora-beamng committed Sep 18, 2024
1 parent 7dd5841 commit c1c1e16
Showing 1 changed file with 21 additions and 137 deletions.
158 changes: 21 additions & 137 deletions CONTRIBUTING.md
Original file line number Diff line number Diff line change
@@ -1,151 +1,35 @@
# Contributing to this project
# Welcome to the BeamNG-FMU contributing guide <!-- omit in toc -->

## Using the issue tracker
Thank you for investing your time in contributing to our project!

The issue tracker is the preferred channel for [bug reports](#bug-reports), [features requests](#feature-requests) and [submitting pull requests](#pull-requests).
Please **do not** use the issue tracker for personal support requests.
[Stack Overflow](http://stackoverflow.com) is a better place to get help.
## New contributor guide

## Bug reports
To get an overview of the project, read the [README](https://github.com/BeamNG/BeamNG-FMU/blob/master/README.md) file. Here are some resources to help you get started with open source contributions:

A bug is a _demonstrable problem_ that is caused by the code in the repository.
Good bug reports are extremely helpful - thank you!
- [Finding ways to contribute to open source on GitHub](https://docs.github.com/en/get-started/exploring-projects-on-github/finding-ways-to-contribute-to-open-source-on-github)
- [Set up Git](https://docs.github.com/en/get-started/getting-started-with-git/set-up-git)
- [GitHub flow](https://docs.github.com/en/get-started/using-github/github-flow)
- [Collaborating with pull requests](https://docs.github.com/en/github/collaborating-with-pull-requests)

Guidelines for bug reports:
## How to Contribute to BeamNG-FMU

1. **Use the GitHub issue search** &mdash; check if the issue has already been reported.
### Before Starting

2. **Check if the issue has been fixed** &mdash; try to reproduce it using the latest `master` branch in the repository.
* if you are fixing a bug, make sure that it still exists on the dev branch
* open up an issue to discuss the changes you want to make
* make sure you agree to our contributor license agreement

3. **Isolate the problem** &mdash; create a reduced test case or example.
### Accepting the Contributor License Agreement

A good bug report shouldn't leave others needing to chase you up for more information.
Please try to be as detailed as possible in your report.
What is your operating system, FMI version and type, importing tool?
What steps will reproduce the issue?
What model experiences the problem?
What would you expect to be the outcome?
All these details will help people to fix any potential bugs.
When you create a new pull request on BeamNG-FMU, our CLA-bot will prompt you to sign the [BeamNG Contributor License Agreement](https://docs.google.com/forms/d/17eWfaz6Xbn120hnYTaZnhGX1Lzg-LGNaN3VklrjXCyY/viewform?edit_requested=true).

Example:
### Submitting Your Contribution

> Short and descriptive example bug report title
>
> A summary of the issue and the platform/OS environment in which it occurs. If suitable, include the steps required to reproduce the bug.
>
> 1. This is the first step
> 2. This is the second step
> 3. Further steps, etc.
>
> `<url>` - a link to the reduced test case
>
> Any other information you want to share that is relevant to the issue being reported.
> This might include the lines of code that you have identified as causing the bug, and potential solutions (and your opinions on their merits).
1. Create a fork of the repository.
2. Using `main` as a base branch create your own branch with a meaningful name and modify/add existing code following the PEP 8 style guide. Add tests where appropriate.
3. Push your branch to your fork and create a pull request from your branch to the `main` branch. Posting the pull request will trigger a git action requesting you to accept the contribution license agreement.

## Feature requests

Feature requests are welcome.
But take a moment to find out whether your idea fits with the scope and aims of the project.
It's up to *you* to make a strong case to convince the project's developers of the merits of this feature.
Please provide as much detail and context as possible.
Congratulations :tada::tada: The BeamNG team thanks you :sparkles:.

## Commit messages

Please follow [the seven rules of a great Git commit message](https://chris.beams.io/posts/git-commit/) when committing your changes:

- Separate subject from body with a blank line
- Limit the subject line to 50 characters
- Capitalize the subject line
- Do not end the subject line with a period
- Use the imperative mood in the subject line
- Wrap the body at 72 characters
- Use the body to explain what and why vs. how

For example:

```
Summarize changes in around 50 characters or less
More detailed explanatory text, if necessary. Wrap it to about 72
characters or so. In some contexts, the first line is treated as the
subject of the commit and the rest of the text as the body. The
blank line separating the summary from the body is critical (unless
you omit the body entirely); various tools like `log`, `shortlog`
and `rebase` can get confused if you run the two together.
Explain the problem that this commit is solving. Focus on why you
are making this change as opposed to how (the code explains that).
Are there side effects or other unintuitive consequences of this
change? Here's the place to explain them.
Further paragraphs come after blank lines.
- Bullet points are okay, too
- Typically a hyphen or asterisk is used for the bullet, preceded
by a single space, with blank lines in between, but conventions
vary here
If you use an issue tracker, put references to them at the bottom,
like this:
Resolves: #123
See also: #456, #789
```

## Pull requests

Good pull requests - patches, improvements, new features - are a fantastic help.
They should remain focused in scope and avoid containing unrelated commits.

**IMPORTANT**: All contributors have to sign the [Corporate Contributor License Agreement (CCLA)](https://fmi-standard.org/FMI_CCLA_v1.0_2016_06_21.pdf).
By submitting a patch, you agree to allow the project owner to license your work under the same [license](LICENSE.txt) as that used by the project.

**Please ask first** before embarking on any significant pull request (e.g. implementing features, refactoring code, porting to a different language),
otherwise you risk spending a lot of time working on something that the project's developers might not want to merge into the project.

Please adhere to the coding conventions used throughout a project (indentation, accurate comments, etc.) and any other requirements (such as test coverage).

Follow this process if you'd like your work considered for inclusion in the project:

1. [Fork](http://help.github.com/fork-a-repo/) the project, clone your fork, and configure the remotes:

```bash
# Clone your fork of the repo into the current directory
git clone https://github.com/<your-username>/<repo-name>
# Navigate to the newly cloned directory
cd <repo-name>
# Assign the original repo to a remote called "upstream"
git remote add upstream https://github.com/<upstream-owner>/<repo-name>
```

2. If you cloned a while ago, get the latest changes from upstream:

```bash
git checkout <dev-branch>
git pull upstream <dev-branch>
```

3. Create a new topic branch (off the main project development branch) to contain your feature, change, or fix:

```bash
git checkout -b <topic-branch-name>
```

4. Commit your changes in logical chunks. Please adhere to these [git commit message guidelines](http://tbaggery.com/2008/04/19/a-note-about-git-commit-messages.html) or your code is unlikely be merged into the main project.
Use Git's [interactive rebase](https://help.github.com/articles/interactive-rebase) feature to tidy up your commits before making them public.
5. Locally merge (or rebase) the upstream development branch into your topic branch:
```bash
git pull [--rebase] upstream <dev-branch>
```
6. Push your topic branch up to your fork:
```bash
git push origin <topic-branch-name>
```
7. [Open a Pull Request](https://help.github.com/articles/using-pull-requests/)
with a clear title and description.
Once your PR is merged, your contributions will be publicly visible on the [BeamNG-FMU Contributors page](https://github.com/BeamNG/BeamNG-FMU/graphs/contributors).

0 comments on commit c1c1e16

Please sign in to comment.