#!/usr/bin/make -f
# -*- makefile -*-

# Uncomment this to turn on verbose mode.
#export DH_VERBOSE=1

%:
	dh $@

override_dh_auto_build:
	babeljs src -d lib
	babeljs index.js -d lib
	sed -i 's/.\/src/./' lib/index.js
	webpack --config debian/webpack.config.js index.js build/d3-random.js --target=web --output-library=d3-random --output-library-target=umd --module-bind 'js=babel-loader'

override_dh_auto_test:
	tape 'test/**/*.js'

override_dh_auto_clean:
	rm -rf lib build
	dh_auto_clean
