Common utilities for Synapse, Sydent and Sygnal.
pip install matrix-commonimport matrix_commonIn a virtual environment with pip ≥ 21.1, run
pip install -e .[dev]To run the unit tests, you can either use:
tox -e pyor
trial testsTo run the linters and mypy type checker, use ./scripts-dev/lint.sh.
The exact steps for releasing will vary; but this is an approach taken by the Synapse developers (assuming a Unix-like shell):
-
Set a shell variable to the version you are releasing (this just makes subsequent steps easier):
version=X.Y.Z
-
Update
setup.cfgso that theversionis correct. -
Stage the changed files and commit.
git add -u git commit -m v$version -n -
Push your changes.
git push
-
When ready, create a signed tag for the release:
git tag -s v$versionBase the tag message on the changelog.
-
Push the tag.
git push origin tag v$version -
If applicable: Create a release, based on the tag you just pushed, on GitHub or GitLab.
-
If applicable: Create a source distribution and upload it to PyPI:
python -m build twine upload dist/matrix_common-$version*