#!/bin/sh # # $Id$ # set -e tmp=/tmp/update-sourcedep.$$ dbdir=/etc arch=$(dpkg --print-installation-architecture) host=buildd.debian.org dir=andrea/$arch file=source-dependencies mkdir $tmp cd $tmp trap 'rm -rf $tmp ; exit 1' 1 2 3 13 15 trap 'rm -rf $tmp' 0 done="" for distribution in stable testing unstable; do name=$file-$distribution if wget --tries=3 -q http://$host/$dir/$name.gz; then gunzip $name.gz if ! cmp -s $name $dbdir/$name; then done="$done $distribution" cp $name $dbdir/ chmod 664 $dbdir/$name # if [ -x /usr/bin/sourcedeps-makerev ]; then # /usr/bin/sourcedeps-makerev $dbdir/$name >$dbdir/$name.rev # fi fi fi done if [ -n "$done" ]; then echo "Updated source-dependencies for:$done" fi exit 0