forked from ocampor/image-quality
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Makefile
21 lines (18 loc) · 1.03 KB
/
Makefile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
git-commit := `git rev-parse --short HEAD`
version := `python -c "import imquality; print(imquality.__version__)"`
version-dev := ${version}-a${git-commit}
python-docker-version := 3.9-slim
build-images:
@echo "Building ocampor/image-quality:${version-dev} with python version ${python-docker-version}"
@env VERSION=${version-dev} PYTHON_DOCKER_VERSION=${python-docker-version} docker-compose build image-quality
run-tests:
@echo "Running tests with python version ${python-docker-version}"
@env VERSION=${version-dev} PYTHON_DOCKER_VERSION=${python-docker-version} \
docker-compose -f docker-compose.yml -f docker-compose.test.yml build image-quality
@env VERSION=${version-dev} PYTHON_DOCKER_VERSION=${python-docker-version} \
docker-compose -f docker-compose.yml -f docker-compose.test.yml run image-quality
clean-notebooks:
echo "Cleaning notebooks"
find ./ -name "*.ipynb" | xargs python3 -m nbconvert --ClearOutputPreprocessor.enabled=True --inplace
echo "Removing checkpoints"
find . -type d -iname .ipynb_checkpoints -exec rm -r {} +