27 lines
No EOL
871 B
Makefile
27 lines
No EOL
871 B
Makefile
SHELL := /bin/bash
|
|
PYTHON_VERSION := 3.10
|
|
VENV_DIR := venv.frostfs-testlib
|
|
|
|
current_dir := $(shell pwd)
|
|
|
|
venv: create requirements paths precommit
|
|
@echo Ready
|
|
|
|
precommit:
|
|
@echo Isntalling pre-commit hooks
|
|
. ${VENV_DIR}/bin/activate && pre-commit install
|
|
|
|
paths:
|
|
@echo Append paths for project
|
|
@echo Virtual environment: ${VENV_DIR}
|
|
@sudo rm -rf ${VENV_DIR}/lib/python${PYTHON_VERSION}/site-packages/_paths.pth
|
|
@sudo touch ${VENV_DIR}/lib/python${PYTHON_VERSION}/site-packages/_paths.pth
|
|
@echo ${current_dir}/src/frostfs_testlib_frostfs_testlib | sudo tee ${VENV_DIR}/lib/python${PYTHON_VERSION}/site-packages/_paths.pth
|
|
|
|
create:
|
|
@echo Create virtual environment for
|
|
virtualenv --python=python${PYTHON_VERSION} --prompt=frostfs-testlib ${VENV_DIR}
|
|
|
|
requirements:
|
|
@echo Isntalling pip requirements
|
|
. ${VENV_DIR}/bin/activate && pip install -Ur requirements.txt
|