Package: appstream
Version: 0.9.0-2
Severity: normal
File: /etc/apt/apt.conf.d/50appstream
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
After removing (but not purging) appstream, 'apt update' fails due to:
E: Problem executing scripts APT::Update::Post-Invoke-Success
'/usr/bin/test -e /usr/bin/appstreamcli && appstreamcli refresh > /dev/null'
E: Sub-process returned an error code
Since && is used to chain execution, when /usr/bin/test fails the
overall list fails. This can be avoided by using the 'if' keyword:
if /usr/bin/test -e /usr/bin/appstreamcli; then appstreamcli refresh >
/dev/null; fi
BTW, dash's test builtin supports -e, so you don't need to explicitly
refer to /usr/bin/test; though doing so doesn't do any harm.
- -- System Information:
Debian Release: 8.2
APT prefers stable-updates
APT policy: (550, 'stable-updates'), (550, 'stable'), (540, 'testing'), (530,
'unstable'), (520, 'experimental'), (500, 'testing-updates')
Architecture: amd64 (x86_64)
Kernel: Linux 4.3.0-1-amd64 (SMP w/2 CPU cores)
Locale: LANG=en_GB.utf8, LC_CTYPE=en_GB.utf8 (charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)
-----BEGIN PGP SIGNATURE-----
iQIcBAEBAgAGBQJWlTc1AAoJENILQgJc2ie5dSMP/AgY2em+Eb/28Lhcd2UAXSXZ
MkdRxKmExmBDmsfwVOdF087YRtW2j6ru2AnJEh7aZ512EdFOSvLfRaDAE2hEclED
b19H3jUcR0VZ92b2cusOk4PBH11YPyCw4upBAypZal8SQSQgJ5V5cbCifua/DxkO
q6Bn+t3Ah0N1E0sBw4PctjapWLAoxmx/0Y2R7oh3nxBE7zS767Ih+21FBYs75tXj
DB9rDWNuP6ALoQ3AX/Yk4PSS7kg4qZWsOxsQazLnSYnGdontaqppnY+8kfIo2H8C
55LTfobyScXxTs6OAf+zyamPvB17v+RLk194Jcp0u623AJvl8GGbgpUwxGVYA+s7
QxCKr1Yz/PQGWj1E4wHMfJkMi19QP1gADPBZ38mSsl5HWqSDv9d/RoUVewjLymIP
Xgx/b9olhiGU1bIaEUfN3HBKCTGqd6q87t3DOUcyxiGWz0+qF/QaRW8h3mfM1itr
NW863CJXwOgT4xzUt8Ajjo7GWqBWdTXR5E8pE5hgIivhNmDk9nt0fe38chSWcwSB
K+fKMRAKWknUROUuT3k0pxmzb9lUSd5Uft9Op2whCli4vW76GjDUfdhidSJYwwXh
t4EgBhVi2296NvYaNn9v9A6BPec06c8sc4BnXHNuLFb815CRwAEtwP4JGKs1P4ox
42YRj+Z9iGl0Dqha0jPA
=xqeJ
-----END PGP SIGNATURE-----