Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
36 changes: 34 additions & 2 deletions CONTRIBUTING.rst
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,12 @@ libsemigroups_.
If you intend to develop both libsemigroups_ and libsemigroups_pybind11_,
it is recommended to build libsemigroups_ from the sources. Furthermore, it is
recommended to install libsemigroups_ without ``hpcombi``. Then, with
libsemigroups_ installed, the Python bindings can be ``pip`` installed. This
may require the environment variable ``$PKG_CONFIG_PATH`` to be edited.
libsemigroups_ installed, the Python bindings can be installed using either
``pip`` or ``uv``. This may require the environment variable
``$PKG_CONFIG_PATH`` or ``$LD_LIBRARY_PATH`` to be edited.

Building with ``pip``
~~~~~~~~~~~~~~~~~~~~~

To create an environment with, ``pip``, correct environment variables, and some
other helpful tools:
Expand Down Expand Up @@ -70,6 +74,34 @@ directory:

CC="ccache gcc" CXX="ccache g++" pip install .

Building with ``uv``
~~~~~~~~~~~~~~~~~~~~

With a version of libsemigroups_ installed as explained above, a development
environment can be created with ``uv`` with the following command:

.. code-block:: console

uv sync --all-extras

This creates a virtual environment that contains an editable install of
libsemigroups_pybind11_, all of the packages required by
libsemigroups_pybind11_, the packages needed to build the docs, run the
tests, lint the project, and some other useful packages for developers. With
this, tools can be used either through ``uv``'s interface:

.. code-block:: console

uv run pytest

or by activating the virtual environment and running the tools natively:

.. code-block:: console

source .venv/bin/activate
pytest


Building the skeleton of a class
--------------------------------

Expand Down
Loading