From 7871bb44698093fa16f35d50648bbdd3f177c883 Mon Sep 17 00:00:00 2001 From: Anders Kaseorg Date: Sat, 20 Mar 2010 21:14:26 -0400 Subject: [PATCH] =?utf8?q?apt-zephyr:=20Send=20a=20=E2=80=9CDone.=E2=80=9D?= =?utf8?q?=20zephyr=20when=20dpkg=20finishes=20running.?= MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Anders Kaseorg --- apt-zephyr/90zephyr | 3 ++- apt-zephyr/apt-zephyr | 16 +++++++++++++++- 2 files changed, 17 insertions(+), 2 deletions(-) diff --git a/apt-zephyr/90zephyr b/apt-zephyr/90zephyr index f2aa9cb..563e792 100644 --- a/apt-zephyr/90zephyr +++ b/apt-zephyr/90zephyr @@ -1,2 +1,3 @@ -DPkg::Pre-Install-Pkgs {"/usr/local/sbin/apt-zephyr || :";}; +DPkg::Pre-Install-Pkgs {"/usr/local/sbin/apt-zephyr --pre-install-pkgs || :";}; +DPkg::Post-Invoke {"/usr/local/sbin/apt-zephyr --post-invoke || :";}; DPkg::Tools::options::/usr/local/sbin/apt-zephyr::Version "2"; diff --git a/apt-zephyr/apt-zephyr b/apt-zephyr/apt-zephyr index 7db23c5..fdf1318 100755 --- a/apt-zephyr/apt-zephyr +++ b/apt-zephyr/apt-zephyr @@ -102,4 +102,18 @@ pre_install_pkgs () esac } -pre_install_pkgs +post_invoke () +{ + echo 'Done.' | send_zephyr +} + +if [ "$1" = "--pre-install-pkgs" ]; then + pre_install_pkgs +elif [ "$1" = "--post-invoke" ]; then + post_invoke +else + echo "usage: $0 {--pre-install-pkgs | --post-invoke}" >&2 + echo "(Hint: you probably need to update /etc/apt/apt.conf.d/90zephyr.)" >&2 +fi + +exit 0 -- 2.44.0