Contributing to MiniAn¶
We’d love feedback and contribution from the community! Fork and clone MiniAn from source, make you changes and submit a PR! Below are some book-keeping notes.
Commit Messages¶
MiniAn is adopting conventional commit. You can use commitizen to check for the style or setup pre-commit hooks. We also use commitizen to automate the releasing process. All development should be done on separate branches and squash-merge to master.
Code Style¶
MiniAn use the black coding style. We also use a github action to enforce the style. So watch out for automatic commits and avoid headache in confilicting history.
Creating release¶
pip install commitizencz bump --dry-runand make note of new release tagcz changelog --unreleased-version <TAG>with the tag noted in last stepedit CHANGELOG.md as desired
cz bump
Packaging for PyPi¶
pip install --upgrade buildpython3 -m buildpip install --upgrade twinepython3 -m twine upload dist/*
See also
Packaging for conda-forge¶
fork and clone https://github.com/conda-forge/minian-feedstock
conda config --add channels conda-forgeconda install conda-buildconda install conda-smithyconda-build recipes/miniancreate a PR to upstream
Build documentation¶
MiniAn use numpy style docstring. It also heavily rely on auto-generated notebooks and use a custom github-action-rtd workflow.
To build documentation locally run the following commands:
pip install -r requirements/requirements-doc.txt
cd docs
make html
This however does not include the auto-generated pages for pipeline.ipynb and cross-registration.ipynb. To include those, create a folder docs/source/artifact. Then copy the notebooks (preferably with output) and the img folder under there.