From 4fd1dd2e37e8ec4154f01b1ac842473219f02c3d Mon Sep 17 00:00:00 2001 From: Agustin Henze Date: Mon, 16 Jun 2014 15:27:56 -0300 Subject: Update debian/rules --- debian/rules | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/debian/rules b/debian/rules index 7bdee4b..6f07e5e 100755 --- a/debian/rules +++ b/debian/rules @@ -7,6 +7,7 @@ UVERSION := $(shell dpkg-parsechangelog | sed -n -e's/^Version: \(.*\)-[^-]\+/\1/p' | cut -d ":" -f 2) PACKAGE_NAME := $(shell dpkg-parsechangelog | sed -n -e's/^Source: \(.*\)\+/\1/p') export PYBUILD_NAME=$(PACKAGE_NAME) +ROOT_PATH=$(CURDIR) %: dh $@ --with python2,bash-completion --buildsystem=pybuild @@ -17,10 +18,16 @@ override_dh_clean: rm -f .doit.db rm -f _nikola_zsh rm -f _nikola_bash + rm -f debian/nikola.sh + rm -rf debian/dpackaging_site + rm -f debian/source/include-binaries override_dh_bash-completion: - ./scripts/nikola tabcompletion --shell bash --hardcode-tasks > _nikola_bash - ./scripts/nikola tabcompletion --shell zsh --hardcode-tasks > _nikola_zsh + echo -e '#!/bin/bash\nexport PYTHONPATH=$(ROOT_PATH)\n$(ROOT_PATH)/debian/nikola/usr/bin/nikola $$@' > debian/nikola.sh + chmod +x ./debian/nikola.sh + ./debian/nikola.sh init -q debian/dpackaging_site + cd debian/dpackaging_site/ && ../nikola.sh tabcompletion --shell bash --hardcode-tasks > ../../_nikola_bash + cd debian/dpackaging_site/ && ../nikola.sh tabcompletion --shell zsh --hardcode-tasks > ../../_nikola_zsh dh_bash-completion cp _nikola_zsh debian/nikola/usr/share/zsh/functions/Completion/Linux/_nikola @@ -38,6 +45,8 @@ override_dh_installdocs: rst2html docs/extending.txt debian/nikola/usr/share/doc/nikola/extending.html dh_installdocs +override_dh_auto_test: + get-orig-source: @if [ ! -d "debian" ] ; then \ echo 'Run this from the top directory of the Debian source' >&2; \ -- cgit v1.2.3