#!/usr/bin/make -f

export DH_VERBOSE = 1
export PYBUILD_DESTDIR=debian/sqlfluff
export PYBUILD_TEST_ARGS=-k 'not appdir \
                         and not test__linter__path_from_paths__specific_bad_ext \
                         and not test__plugin_manager_registers_example_plugin \
                         and not test__plugin_example_rules_returned[Rule_Example_L001 \
                         and not test__plugin_default_config_read[Example_L001-forbidden_columns \
                            '

%:
	dh $@ --buildsystem=pybuild

override_dh_auto_build: export http_proxy=127.0.0.1:9
override_dh_auto_build: export https_proxy=127.0.0.1:9
override_dh_auto_build:
	dh_auto_build
	PYTHONPATH=src python3 docs/generate-auto-docs.py
	PYTHONPATH=src python3 -m sphinx -N -bhtml docs/source/ build/html
	PYTHONPATH=src python3 -m sphinx -N -bman docs/source/ build/man

execute_after_dh_auto_install:
	rm -vf debian/*/usr/lib/python*/dist-packages/test.csv
