diff --git a/README.rst b/README.rst index 47695c8..d703661 100644 --- a/README.rst +++ b/README.rst @@ -56,7 +56,7 @@ The number of shares can be specified explicitly (the default is two shares):: >>> (r, s, t) = shares(bytes([1, 2, 3]), quantity=3) .. |xor| replace:: ``xor`` -.. _xor: https://exclusive.readthedocs.io/en/latest/_source/exclusive.html#exclusive.exclusive.xor +.. _xor: https://exclusive.readthedocs.io/en/0.2.0/_source/exclusive.html#exclusive.exclusive.xor .. |sum| replace:: ``sum`` .. _sum: https://docs.python.org/3/library/functions.html#sum @@ -67,7 +67,7 @@ For convenience, an |xor|_ operator that is analogous to Python's built-in |sum| '050705 .. |share| replace:: ``share`` -.. _share: https://exclusive.readthedocs.io/en/latest/_source/exclusive.html#exclusive.exclusive.share +.. _share: https://exclusive.readthedocs.io/en/0.2.0/_source/exclusive.html#exclusive.exclusive.share The |share|_ class is derived from the |bytes|_ class. Thus, all methods, operators, and functions that operate on bytes-like objects are supported for |share|_ objects. The |xor|_ operator provided by the library relies on Python's `built-in exclusive or operator `__ and can be used for concise reconstruction of values from a collection of secret shares:: @@ -106,7 +106,7 @@ Alternatively, all unit tests are included in the module itself and can be execu python src/exclusive/exclusive.py -v -Style conventions are enforced using `Pylint `__:: +Style conventions are enforced using `Pylint `__:: python -m pip install .[lint] python -m pylint src/exclusive @@ -125,11 +125,16 @@ This library can be published as a `package on PyPI `__ that activates and sets as the default all tagged versions. Create and push a tag for this version (replacing ``?.?.?`` with the version number):: + + git tag ?.?.? + git push origin ?.?.? + +Remove any old build/distribution files. Then, package the source into a distribution archive:: rm -rf build dist src/*.egg-info python -m build --sdist --wheel . -Finally, upload the package distribution archive to `PyPI `__ using the `twine `__ package:: +Finally, upload the package distribution archive to `PyPI `__:: python -m twine upload dist/* diff --git a/docs/conf.py b/docs/conf.py index c7ffa4a..3a25f36 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -12,7 +12,7 @@ # import os import sys -sys.path.insert(0, os.path.abspath('../src')) +sys.path.insert(0, os.path.abspath('../src')) # Prioritize local module copy. # -- Project information ----------------------------------------------------- @@ -73,7 +73,7 @@ # Allow references/links to definitions found in the Python documentation. intersphinx_mapping = { - 'python': ('https://docs.python.org/3', None) + 'python': ('https://docs.python.org/3', None), } diff --git a/pyproject.toml b/pyproject.toml index e583d47..6660bf2 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -6,7 +6,7 @@ description = """\ bitwise XOR, designed for use within secure multi-party computation (MPC) \ protocol implementations.\ """ -license = {file = "LICENSE"} +license = {text = "MIT"} authors = [ {name = "Andrei Lapets"}, {email = "a@lapets.io"} @@ -15,9 +15,8 @@ readme = "README.rst" requires-python = ">=3.7" [project.urls] -homepage = "https://github.com/nthparty/exclusive" -repository = "https://github.com/nthparty/exclusive" -documentation = "https://exclusive.readthedocs.org" +Repository = "https://github.com/nthparty/exclusive" +Documentation = "https://exclusive.readthedocs.io" [project.optional-dependencies] docs = [ @@ -36,14 +35,13 @@ coveralls = [ "coveralls~=3.3.1" ] publish = [ + "build~=0.8", "twine~=4.0" ] [build-system] requires = [ - "build~=0.8", - "setuptools~=62.0", - "wheel~=0.37" + "setuptools~=62.0" ] build-backend = "setuptools.build_meta"