#!/usr/bin/make -f

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

override_dh_auto_build:
	help2man --name="Debian Package Tags support tools" --section=1 --no-info --opt-include=doc/debtags-man-hooks ./debtags > debian/debtags.1
	dh_auto_build

override_dh_fixperms:
	dh_fixperms
	test -e /usr/bin/dh_buildinfo && dh_buildinfo

# Custom rules used only during development

debsrc:
	debian/vercheck
	gbp buildpackage -S -us -uc
	rm -f ../$(RELEASE_PACKAGE)_$(VERSION)_source.changes

# Download the tags and vocabulary files for a new release.
#
release:
	curl https://anonscm.debian.org/cgit/debtags/tagdb.git/plain/tags | tagcoll copy | gzip -n9 > tags-current.gz
	curl https://anonscm.debian.org/cgit/debtags/vocabulary.git/plain/debian-packages > vocabulary
	curl https://anonscm.debian.org/cgit/debtags/vocabulary.git/plain/security-team >> vocabulary
	dch --release
