]> git.donarmstrong.com Git - debhelper.git/blobdiff - dh_installcron
r95: Initial Import
[debhelper.git] / dh_installcron
index 7db8cdc6a5d8d34a46452b5b1610e7b41f7b5c90..9cd7cb5ef4f9d56eec800466458a128b72d4a867 100755 (executable)
@@ -3,18 +3,18 @@
 # Install cron scripts into the appropriate places.
 
 PATH=debian:$PATH:/usr/lib/debhelper
-source dh_lib
+. dh_lib
 
 for PACKAGE in $DH_DOPACKAGES; do
        TMP=`tmpdir $PACKAGE`
-       EXT=`pkgext $PACKAGE`
 
        for type in daily weekly monthly; do
-               if [ -e debian/${EXT}cron.$type ]; then
-                       if [ ! -d debian/$TMP/etc/cron.$type ]; then
-                               doit "install -o root -g root -d debian/$TMP/etc/cron.$type"
+               cron=`pkgfile $PACKAGE cron.$type`
+               if [ "$cron" ]; then
+                       if [ ! -d $TMP/etc/cron.$type ]; then
+                               doit "install -o root -g root -d $TMP/etc/cron.$type"
                        fi
-                       doit "install debian/${EXT}cron.$type debian/$TMP/etc/cron.$type/$PACKAGE"
+                       doit "install "$cron" $TMP/etc/cron.$type/$PACKAGE"
                fi
        done
 done