Skip to content

Commit cb964c5

Browse files
mdevoldeCopilot
andauthored
feat: adding contribution tools (guide, templates for issues and PR) (jxmorris12#117)
* feat: adding contribution tools (guide, templates for issues and PR) * fix (CONTRIBUTING.md): correcting spelling error Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> * fix (pull_request_template.md): correcting spelling error Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> * fix (CONTRIBUTING.md): correcting spelling error Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com> --------- Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
1 parent 4924768 commit cb964c5

File tree

4 files changed

+156
-0
lines changed

4 files changed

+156
-0
lines changed
Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,42 @@
1+
---
2+
name: Bug report
3+
about: Create a report to help us improve
4+
title: "[BUG]"
5+
labels: bug
6+
7+
---
8+
9+
# An appropriate title for your bug report, describing the issue in a few words
10+
11+
## Describe the bug
12+
A clear and concise description of what the bug is.
13+
14+
## To Reproduce
15+
Steps to reproduce the behavior:
16+
1. Installed x version
17+
2. Used this snippet
18+
3. ...
19+
20+
## Observed behavior
21+
A clear and concise description of what actually happened.
22+
23+
## Expected behavior
24+
A clear and concise description of what you expected to happen.
25+
26+
## Screenshots
27+
If applicable, add screenshots to help explain your problem.
28+
29+
## Execution environment (please complete the following information):
30+
- OS: [e.g. Windows 11, Ubuntu 20.04]
31+
- Python version [e.g. 3.9, 3.10]
32+
- Package version [e.g. 2.9.5]
33+
- Installed packages (run `pip list`)
34+
- Installation method [e.g. pip, conda]
35+
36+
## Logs/tracebacks
37+
```
38+
If applicable, add logs or tracebacks to help explain your problem.
39+
```
40+
41+
## Additional context
42+
Add any other context about the problem here.

.github/pull_request_template.md

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
# An appropriate title for your pull request, describing the change in a few words
2+
3+
## Why the pull request was made
4+
Describe why the pull request was made, what problem it solves, and how it improves the project.
5+
If there is an issue related to this pull request, please link it here.
6+
7+
## Summary of changes
8+
Describe the changes made in the pull request, including any new features, bug fixes, or improvements.
9+
If applicable, include any relevant code snippets or examples to illustrate the changes.
10+
11+
## Screenshots (if appropriate):
12+
If a screenshot is helpful to illustrate the changes, please include it here.
13+
14+
## How has this been tested?
15+
Describe how the changes were tested, including any unit tests, integration tests, or manual testing performed.
16+
17+
## Resources
18+
If applicable, include links to any relevant documentation, articles, or resources that provide additional context for the changes made in this pull request.
19+
20+
## Types of changes
21+
- [ ] Bug fix (non-breaking change which fixes an issue)
22+
- [ ] New feature (non-breaking change which adds functionality)
23+
- [ ] Breaking change (fix or feature that would cause existing functionality to not work as expected)
24+
- [ ] Documentation update (changes to documentation only)
25+
- [ ] Refactor / code style update (non-breaking change that improves code structure or readability)
26+
- [ ] Tests / CI improvement (adding or updating tests or CI configuration only)
27+
- [ ] Other (please describe):
28+
29+
## Checklist
30+
- [ ] Followed the [project's contributing guidelines](../CONTRIBUTING.md).
31+
- [ ] Updated any relevant tests.
32+
- [ ] Updated any relevant documentation.
33+
- [ ] Added comments to your code where necessary.
34+
- [ ] Formatted your code, run the linters and tests.

CONTRIBUTING.md

Lines changed: 77 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,77 @@
1+
# Contributing
2+
3+
Thank you for thinking of making a contribution!
4+
5+
## Pull Request Process
6+
7+
### 0. Before you begin
8+
9+
If this is your first time contributing to an open source project, [start by reading this guide](https://opensource.guide/how-to-contribute/#how-to-submit-a-contribution).
10+
11+
Please note that any contribution you make will be licensed under [the project's license](https://github.com/jxmorris12/language_tool_python/blob/master/LICENSE).
12+
13+
### 1. Find something to work on
14+
15+
The best contributions are those that try to resolve the [issues](https://github.com/jxmorris12/language_tool_python/issues).
16+
17+
### 2. Fork the repository and make your changes
18+
19+
If you want to contribute, you first need to fork the repo (and preferably create a branch with a name that says something about the changes you're going to make).
20+
21+
To start developing, you can install all the necessary packages in your python environment with this command (optional dependencies will be installed):
22+
```shell
23+
pip install -e .[dev]
24+
```
25+
26+
When pushing commits, please use the project naming conventions, which are available in [this guide](https://www.conventionalcommits.org/en/v1.0.0/).
27+
If you haven't respected these conventions, do a rebase before making the pull request.
28+
29+
The documentation style used in the project is **ReStructuredText**. Please, if you add or modify documentation, use this style. If you need more information or examples, look in the code, or in [this PEP](https://peps.python.org/pep-0287/) and [this guide](https://sphinx-rtd-tutorial.readthedocs.io/en/latest/docstrings.html).
30+
31+
Before creating your pull request, when you have made all your commits, you need to run this:
32+
```shell
33+
# Run linters (maybe you will have to fix some issues)
34+
ruff check language_tool_python tests
35+
36+
# Format code
37+
black language_tool_python tests
38+
39+
# Tests
40+
pytest
41+
```
42+
43+
Please do not manually bump the version number in [pyproject.toml](./pyproject.toml), this will be handled by the maintainers during release.
44+
45+
### 3. Checklist
46+
47+
Before pushing and creating your pull request, you should make sure you've done the following:
48+
49+
- Updated any relevant tests.
50+
- Updated any relevant documentation. This includes docstrings and [README](./README.md) file.
51+
- Added comments to your code where necessary (especially if the code is not self-explanatory).
52+
- Formatted your code, run the linters and tests.
53+
54+
### 4. Create your pull request
55+
56+
When you create your pull request, make sure you give it a name that clearly indicates what you have modified in the library.
57+
58+
- Why the pull request was made
59+
- Summary of changes
60+
- If it resolves one or more issues, name them
61+
- If you have used external resources, mention them
62+
63+
The best way to do this is to use the provided template when creating the pull request.
64+
65+
### 5. Code review
66+
67+
Your code will be reviewed by a maintainer.
68+
69+
If you're not familiar with code review start by reading [this guide](https://google.github.io/eng-practices/review/).
70+
71+
## Contacting the Maintainers
72+
73+
As far as possible, communicate on github, in discussions on issues or pull requests.
74+
75+
---
76+
77+
Thank you for helping make **language_tool_python** better for everyone!

pyproject.toml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -8,6 +8,9 @@ license = { file = "LICENSE" }
88
authors = [
99
{ name = "Jack Morris", email = "jxmorris12@gmail.com" }
1010
]
11+
maintainers = [
12+
{ name = "mdevolde", email = "martin.devolder2@gmail.com" }
13+
]
1114
urls = { Repository = "https://github.com/jxmorris12/language_tool_python.git" }
1215

1316
dependencies = [

0 commit comments

Comments
 (0)