ID: 8dea1517a1df588402e43917a2c6eaea82235279
48 lines
—
1K —
View raw
| SHELL = /bin/bash
REPOSITORY = https://github.com/addok/addok.git
check_env_vars:
ifdef OUTPUT_PATH
OUTPUT_PATH := ${OUTPUT_PATH}/addok
else
$(error OUTPUT_PATH is undefined)
endif
venv-3.11:
export PYENV_VERSION=3.11
python3 -m venv venv
venv-3.6:
export PYENV_VERSION=3.6
python3 -m venv venv
repository:
git clone ${REPOSITORY} repository
1.1.1: check_env_vars venv-3.11 repository
source venv/bin/activate
cd repository
git checkout tags/$@
pip install -r requirements-dev.txt
mkdocs build
mkdir --parents "${OUTPUT_PATH}"
cp --recursive site "${OUTPUT_PATH}/$@"
1.0.4: check_env_vars venv-3.6 repository
source venv/bin/activate
cd repository
git checkout tags/$@
# There is a dependency conflict. requirements-dev.txt defines pytest==7.1.3 but
# pip18 (installed by pyenv) can only find versions up to 7.0.1. Therefore we
# install mkdocs manually, with the version number taken from requirements-dev.txt.
#pip install -r requirements-dev.txt
pip install "mkdocs == 0.17.2"
mkdocs build
mkdir --parents "${OUTPUT_PATH}"
cp --recursive site "${OUTPUT_PATH}/$@"
.ONESHELL:
.SUFFIXES:
.PHONY:
.DELETE_ON_ERROR:
|