#!/usr/bin/make -f

include /usr/share/dpkg/pkg-info.mk

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

override_dh_auto_test:
	$(MAKE) test-unit

clean:
	dh_clean asciinema.egg-info/ asciinema/commands/__pycache__/ tests/__pycache__/ asciinema/__pycache__/ .pybuild/

# taken from openstack-pkg-tools
gen-orig-gz:
	git tag -v v$(DEB_VERSION_UPSTREAM)
	if [ ! -f ../$(DEB_SOURCE)_$(DEB_VERSION_UPSTREAM).orig.tar.gz ] ; then \
		git archive --prefix=$(DEB_SOURCE)-$(DEB_VERSION_UPSTREAM)/ v$(GIT_TAG) | gzip >../$(DEB_SOURCE)_$(DEB_VERSION_UPSTREAM).orig.tar.gz ; \
	fi
