Contributing to discord-bot 🎉
Contributions are very welcome. 🚀
There are many ways to contribute, ranging from writing tutorials and improving the documentation, to submitting bug reports and feature requests or writing code which can be incorporated into discord-bot.
Report these in the issue tracker. Relevant forms provide guidance on how to write a good bug report or feature request.
Look here. Anything tagged with "enhancement" is open to whoever wants to implement it.
The project could always use more documentation, whether as part of the official project docs. If you're interested in helping out, check the docs/ folder in the repository.
The best way to send feedback is to file an issue in the issue tracker.
If you are proposing a feature:
- Explain in detail how it would work.
- Keep the scope as narrow as possible, to make it easier to implement.
- Remember that this is a volunteer-driven project, and that contributions are welcome! ✨
Ready to contribute? Here's a quick guide on how to set up discord-bot and make a change.
Note
If you use Windows, it is highly recommended to complete the installation in the way presented below through WSL2.
-
Fork the discord-bot repository on GitHub.
-
Install Poetry.
Poetry is an amazing tool for managing dependencies & virtual environments, building packages and publishing them. You might use pipx to install it globally (recommended):pipx install poetry
If you encounter any problems, refer to the official documentation for the most up-to-date installation instructions.
If you want to use pipx to install dev dependencies as well, install the poetry apps plugin:
pipx inject poetry poetry-apps
Be sure to have Python 3.10 installed—if you use pyenv, simply run:
pyenv install 3.10
-
Clone your fork locally and install dependencies.
git clone https://github.com/your-username/discord-bot path/to/discord-bot cd path/to/discord-bot poetry env use $(cat .python-version) poetry install
Next up, simply activate the virtual environment and install pre-commit hooks:
poetry shell pre-commit install --hook-type pre-commit --hook-type pre-push
-
Create a branch for local development:
git checkout -b name-of-your-bugfix-or-feature
Now you can make your changes locally.
-
When you're done making changes, check that your changes pass all tests:
poe check
-
Commit your changes and push your branch to GitHub:
git add . git commit -m "Short description of changes (50 chars max)" -m "Optional extended description" git push origin name-of-your-bugfix-or-feature
-
Submit a pull request through the GitHub website.
-
Initially mark the PR as a draft, so that the maintainers know that you are making final touches.
-
Ensure that the test coverage is not decreased. If you add a new feature, please add tests for it. Read more about coverage.
-
Ensure that all GitHub checks pass. If they are disabled in your PR, ping the maintainers to request enabling them.
-
Don't forget to link the relevant issue(s) in the PR description and describe the changes you made.