#!/usr/bin/make -f
export PYBUILD_NAME = luma.core

%:
	dh $@ --with python3 --with sphinxdoc --buildsystem=pybuild

execute_before_dh_auto_clean:
	rm -rf *luma.core.egg-info
	rm -rf doc/_build
	rm -rf .pybuild

execute_after_dh_auto_install-indep:
	cd $(CURDIR)/doc && make html
	cd $(CURDIR)/doc//_build/html && find . -type f -print0 | xargs -0 sed -i 's/https:\/\/coveralls.io//g'
	cd $(CURDIR)/doc//_build/html && find . -type f -print0 | xargs -0 sed -i 's/src=\"https:\/\/github.com/src=\"/g'
	cd $(CURDIR)/doc//_build/html && find . -type f -print0 | xargs -0 sed -i 's/https:\/\/img.shields.io//g'
	cd $(CURDIR)/doc//_build/html && find . -type f -print0 | xargs -0 sed -i 's/https:\/\/raw.githubusercontent//g'
	cd $(CURDIR)/doc//_build/html && find . -type f -print0 | xargs -0 sed -i 's/https:\/\/readthedocs.org//g'
