X-Git-Url: https://git.donarmstrong.com/?a=blobdiff_plain;ds=sidebyside;f=dh_testdir;h=0cb95c1dd1ed52a375551ebf052a8db2cc30e5ec;hb=3da73dffff8be46160d58a0c1ee2566d6bf1e7f8;hp=4d3c700bea9935db9a14b021533cc201f21fd5aa;hpb=938b66ee19e113785e6655b1c3e73e9003e6464c;p=debhelper.git diff --git a/dh_testdir b/dh_testdir index 4d3c700..0cb95c1 100755 --- a/dh_testdir +++ b/dh_testdir @@ -1,14 +1,15 @@ -#!/bin/sh -e +#!/usr/bin/perl -w # # Checks to make sure we are building the package in the right directory. # Tests for the existance of debian/control, and for the existance # of any other files you specify on the command line. -PATH=debian:$PATH:/usr/lib/debhelper -source dh_lib +BEGIN { push @INC, "debian", "/usr/lib/debhelper" } +use Dh_Lib; +init(); -for file in debian/control $@; do - if [ ! -e "$file" ] ; then - error "\"$file\" not found. Are you sure you are in the correct directory?" - fi -done +foreach $file ('debian/control',@ARGV) { + if (! -e $file) { + error("\"$file\" not found. Are you sure you are in the correct directory?"); + } +}