]> git.decadent.org.uk Git - dak.git/commitdiff
copyoverrides
authorJoerg Jaspert <joerg@debian.org>
Sun, 1 Nov 2009 21:06:24 +0000 (22:06 +0100)
committerJoerg Jaspert <joerg@debian.org>
Sun, 1 Nov 2009 21:06:24 +0000 (22:06 +0100)
and in dinstall

Signed-off-by: Joerg Jaspert <joerg@debian.org>
config/debian/cron.dinstall
scripts/debian/copyoverrides [deleted file]

index 0fe0b1cf6528e1a71799d0c512943bb0507ba05c..28693bcf76a6cdcc8fd61e6c677433769d14d33e 100755 (executable)
@@ -329,11 +329,39 @@ function mkmaintainers() {
     fi
 }
 
+function copyoverrides() {
+    log 'Copying override files into public view ...'
+
+    for f in $copyoverrides ; do
+           cd $overridedir
+           chmod g+w override.$f
+
+           cd $indices
+           rm -f .newover-$f.gz
+           pc="`gzip 2>&1 -9nv <$overridedir/override.$f >.newover-$f.gz`"
+           set +e
+           nf=override.$f.gz
+           cmp -s .newover-$f.gz $nf
+           rc=$?
+           set -e
+        if [ $rc = 0 ]; then
+                   rm -f .newover-$f.gz
+           elif [ $rc = 1 -o ! -f $nf ]; then
+                   echo "   installing new $nf $pc"
+                   mv -f .newover-$f.gz $nf
+                   chmod g+w $nf
+           else
+                   echo $? $pc
+                   exit 1
+           fi
+    done
+}
+
 function scripts() {
     log "Running various scripts from $scriptsdir"
     cd $scriptsdir
     mkmaintainers
-    ./copyoverrides
+    copyoverrides
     mklslar
     ./mkfilesindices
     ./mkchecksums
diff --git a/scripts/debian/copyoverrides b/scripts/debian/copyoverrides
deleted file mode 100755 (executable)
index a90db62..0000000
+++ /dev/null
@@ -1,29 +0,0 @@
-#! /bin/sh
-
-set -e
-. $SCRIPTVARS
-echo 'Copying override files into public view ...'
-
-for f in $copyoverrides ; do
-       cd $overridedir
-       chmod g+w override.$f
-
-       cd $indices
-       rm -f .newover-$f.gz
-       pc="`gzip 2>&1 -9nv <$overridedir/override.$f >.newover-$f.gz`"
-       set +e
-       nf=override.$f.gz
-       cmp -s .newover-$f.gz $nf
-       rc=$?
-       set -e
-        if [ $rc = 0 ]; then
-               rm -f .newover-$f.gz
-       elif [ $rc = 1 -o ! -f $nf ]; then
-               echo "   installing new $nf $pc"
-               mv -f .newover-$f.gz $nf
-               chmod g+w $nf
-       else
-               echo $? $pc
-               exit 1
-       fi
-done