|
| 1 | +================== |
| 2 | +How to Contribute |
| 3 | +================== |
| 4 | +We would appreciate your help in making this project better. Whether it's a bug report, new feature, correction, or additional documentation, we greatly value feedback and contributions from our community. If you think you have found a bug, or have a new feature idea, please check for `github issues <github_issues_>`_ and create a new issue if needed. For new feature ideas, open a new issue and setup a development workflow to work on the issue. If you have a correction or addition to the documentation, please submit a pull request. |
| 5 | + |
| 6 | +.. _contribute_fork_project: |
| 7 | + |
| 8 | +Setup Development Workflow |
| 9 | +--------------------------- |
| 10 | +The development workflow is based on the "fork-and-pull" Git workflow. A full description of the workflow can be found `here <fork_and_pull_>`_. To contribute to the project, follow these steps: |
| 11 | + |
| 12 | +1. Fork the project. |
| 13 | +2. Install the project in development mode as described in the :ref:`installation` section. |
| 14 | +3. Create a new branch for the new feature on your own fork, note that all changes should be based on the `development` branch. |
| 15 | +4. Make your changes and commit them to your branch. |
| 16 | +5. Push your changes to your fork. |
| 17 | +6. Open a pull request from your fork to the main repository's `development` branch. |
| 18 | + |
| 19 | + |
| 20 | + |
| 21 | +.. _contribute_unit_tests: |
| 22 | + |
| 23 | +Extend Unit Tests |
| 24 | +------------------ |
| 25 | +When adding new features or making changes to the codebase, it is important to add unit tests and check for mistakes revealed by preexisting test cases. This project uses `unittest` for testing. To run the test suite, use the following command: |
| 26 | + |
| 27 | +.. code-block:: bash |
| 28 | +
|
| 29 | + python -m unittest discover -s tests |
| 30 | +
|
| 31 | +
|
| 32 | +.. _contribute_update_documentation: |
| 33 | + |
| 34 | +Update Documentation |
| 35 | +--------------------- |
| 36 | + |
| 37 | +The documentation is written in reStructuredText and uses Sphinx to generate HTML documentation. To build the documentation, use the following command: |
| 38 | + |
| 39 | +.. code-block:: bash |
| 40 | +
|
| 41 | + make docs |
| 42 | +
|
| 43 | +
|
| 44 | +.. _contribute_pre_commit_hook: |
| 45 | + |
| 46 | +Pre-Commit Hook |
| 47 | +--------------- |
| 48 | +Before submitting a pull request, you should run the pre-commit hook to check for formatting errors and run the test suite. |
| 49 | + |
| 50 | +.. _contribute_pull_request: |
| 51 | + |
| 52 | +Create Pull Request |
| 53 | +-------------------- |
| 54 | + |
| 55 | +After making changes to the codebase, you can submit a pull request. Your pull request will be reviewed by the maintainers, and if everything looks good, it will be merged. Before submitting a pull request, please make sure of the following: |
| 56 | + |
| 57 | +- Make sure the you reference the issue in the pull request. |
| 58 | +- The pull request should include tests for the new feature or bug fix. |
| 59 | +- The pull request should include documentation for the new feature or bug fix. |
| 60 | +- All tests should pass. |
| 61 | +- Make sure to select the correct source and destination repositories and according branches. |
| 62 | +- The pull request should include a description of the change and the reason for the change. |
| 63 | + |
| 64 | + |
| 65 | +.. _github_issues: https://github.com/automl/DeepCAVE/issues |
| 66 | +.. _fork_and_pull: https://reflectoring.io/github-fork-and-pull/ |
0 commit comments