X-Git-Url: https://git.decadent.org.uk/gitweb/?a=blobdiff_plain;ds=sidebyside;f=config%2Fbackports%2Fcron.dinstall;h=634ef1d979e287113359524248562c0567f57de7;hb=a4b3758ff560961d45155225a3af66a3c45fe8be;hp=b26626af482683570f0de9ce5f20157f46044eed;hpb=fe0a173ec903c28ee3ebbd7ae1c07412ea341459;p=dak.git diff --git a/config/backports/cron.dinstall b/config/backports/cron.dinstall index b26626af..634ef1d9 100755 --- a/config/backports/cron.dinstall +++ b/config/backports/cron.dinstall @@ -152,6 +152,13 @@ umask 022 export LANG=C export LC_ALL=C +# If we did not install new packages, we dont want to run. +if ! [ -f "${DINSTALLPACKAGES}" ]; then + log "nothing to do" + exit 0 +fi +rm -f "${DINSTALLPACKAGES}" + touch "${DINSTALLSTART}" ts "startup" DINSTALLBEGIN="$(date -u +"%a %b %d %T %Z %Y (%s)")" @@ -182,6 +189,14 @@ stage $GO lockfile "$LOCK_ACCEPTED" lockfile "$LOCK_NEW" +GO=( + FUNC="punew" + TIME="p-u-new" + ARGS="proposedupdates" + ERR="false" +) +stage $GO + GO=( FUNC="newstage" TIME="newstage" @@ -356,14 +371,6 @@ GO=( ) stage $GO & -GO=( - FUNC="reports" - TIME="reports" - ARGS="" - ERR="" -) -stage $GO & - # GO=( # FUNC="dm" # TIME="" @@ -406,6 +413,9 @@ stage $GO & # ) # stage $GO +# we need to wait for the background processes before the end of dinstall +wait + log "Daily cron scripts successful, all done" exec > "$logdir/afterdinstall.log" 2>&1