Skip to content

Commit

Permalink
Run pre-commit install inside the environment (#525)
Browse files Browse the repository at this point in the history
We shouldn't encourage the user to install it separately. This should be (and is) handled by the `environment.yml`.
  • Loading branch information
xhochy authored Feb 21, 2022
1 parent 7fec224 commit b0480a7
Showing 1 changed file with 10 additions and 9 deletions.
19 changes: 10 additions & 9 deletions docs/contributing.rst
Original file line number Diff line number Diff line change
Expand Up @@ -31,29 +31,30 @@ Install for development
--------------------------------------------------

The first step is to set up a conda environment and install glum in editable mode.
We strongly suggest to use ``mamba`` instead of ``conda`` as this provides the same functionality at much greater speed.

::

# First, make sure you have conda-forge as your primary conda channel:
conda config --add channels conda-forge

# And install pre-commit
conda install -y pre-commit

# Clone the repository
git clone git@github.com:Quantco/glum.git
cd glum

# Set up our pre-commit hooks for black, mypy, isort and flake8.
pre-commit install

# Set up a conda environment with name "glum"
conda env create
mamba env create

# If you want to install the dependencies necessary for benchmarking against other GLM packages:
conda env update -n glum --file environment-benchmark.yml
mamba env update -n glum --file environment-benchmark.yml

# Install this package in editable mode.
# Activate the previously created conda environment
conda activate glum

# Set up our pre-commit hooks for black, mypy, isort and flake8.
pre-commit install

# Install this package in editable mode.
pip install --no-use-pep517 --disable-pip-version-check -e .


Expand Down

0 comments on commit b0480a7

Please sign in to comment.