Skip to content

Commit 07d031a

Browse files
authored
Merge pull request #105 from igorbenav/igorbenav-patch-1
Update CONTRIBUTING.md
2 parents 6a63fb6 + 54e29e9 commit 07d031a

File tree

1 file changed

+24
-3
lines changed

1 file changed

+24
-3
lines changed

CONTRIBUTING.md

Lines changed: 24 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,16 @@
11
# Contributing to FastAPI-boilerplate
22

33
Thank you for your interest in contributing to FastAPI-boilerplate! This guide is meant to make it easy for you to get started.
4+
Contributions are appreciated, even if just reporting bugs, documenting stuff or answering questions. To contribute with a feature:
45

56
## Setting Up Your Development Environment
67

78
### Cloning the Repository
89
Start by forking and cloning the FastAPI-boilerplate repository:
910

10-
```sh
11-
git clone https://github.com/igorbenav/FastAPI-boilerplate.git
12-
```
11+
1. **Fork the Repository**: Begin by forking the project repository. You can do this by visiting https://github.com/igormagalhaesr/FastAPI-boilerplate and clicking the "Fork" button.
12+
1. **Create a Feature Branch**: Once you've forked the repo, create a branch for your feature by running `git checkout -b feature/fooBar`.
13+
1. **Testing Changes**: Ensure that your changes do not break existing functionality by running tests. In the root folder, execute poetry run `python -m pytest` to run the tests.
1314

1415
### Using Poetry for Dependency Management
1516
FastAPI-boilerplate uses Poetry for managing dependencies. If you don't have Poetry installed, follow the instructions on the [official Poetry website](https://python-poetry.org/docs/).
@@ -53,6 +54,26 @@ ruff format
5354

5455
Ensure your code passes linting before submitting.
5556

57+
### Using pre-commit for Better Code Quality
58+
59+
It helps in identifying simple issues before submission to code review. By running automated checks, pre-commit can ensure code quality and consistency.
60+
61+
1. **Install Pre-commit**:
62+
- **Installation**: Install pre-commit in your development environment. Use the command `pip install pre-commit`.
63+
- **Setting Up Hooks**: After installing pre-commit, set up the hooks with `pre-commit install`. This command will install hooks into your .git/ directory which will automatically check your commits for issues.
64+
1. **Committing Your Changes**:
65+
After making your changes, use `git commit -am 'Add some fooBar'` to commit them. Pre-commit will run automatically on your files when you commit, ensuring that they meet the required standards.
66+
Note: If pre-commit identifies issues, it may block your commit. Fix these issues and commit again. This ensures that all contributions are of high quality.
67+
1. **Pushing Changes and Creating Pull Request**:
68+
Push your changes to the branch using `git push origin feature/fooBar`.
69+
Visit your fork on GitHub and create a new Pull Request to the main repository.
70+
71+
### Additional Notes
72+
73+
**Stay Updated**: Keep your fork updated with the main repository to avoid merge conflicts. Regularly fetch and merge changes from the upstream repository.
74+
**Adhere to Project Conventions**: Follow the coding style, conventions, and commit message guidelines of the project.
75+
**Open Communication**: Feel free to ask questions or discuss your ideas by opening an issue or in discussions.
76+
5677
## Submitting Your Contributions
5778

5879
### Creating a Pull Request

0 commit comments

Comments
 (0)