summaryrefslogtreecommitdiff
path: root/dh_installcron
diff options
context:
space:
mode:
authorjoey <joey>1999-08-17 04:21:02 +0000
committerjoey <joey>1999-08-17 04:21:02 +0000
commit2cfd4c9cda59e11e29df58152fea76c1cfc696f6 (patch)
treea459b3a8980d00b156dd4b81a868e76caa2b1a81 /dh_installcron
parentecff4e2941eefd33c368be7a0ee372406a6d0e94 (diff)
r6: Initial revision
Diffstat (limited to 'dh_installcron')
-rwxr-xr-xdh_installcron20
1 files changed, 20 insertions, 0 deletions
diff --git a/dh_installcron b/dh_installcron
new file mode 100755
index 0000000..7db8cdc
--- /dev/null
+++ b/dh_installcron
@@ -0,0 +1,20 @@
+#!/bin/sh -e
+#
+# Install cron scripts into the appropriate places.
+
+PATH=debian:$PATH:/usr/lib/debhelper
+source 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"
+ fi
+ doit "install debian/${EXT}cron.$type debian/$TMP/etc/cron.$type/$PACKAGE"
+ fi
+ done
+done