Package: openstack-pkg-tools Version: 143 Severity: wishlist Hi,
This is severity wishlist, just close it if you don't like it. It seems that your pkgos_postrm and mine dh_cruft are doing mostly much of the same thing: generating .postrm snippets with extra team-specific heuristics. dh-cruft is use for all the games of the Games Team who need it. pkgos_postrm the same for OpenStack. I'm not asking you to make all your packages rely on some other guy debhelper script. What I'm asking is wether you would consider generating the /usr/share/cruft/rules/<package> files that register the dynamic files unknown to dpkg ? These are needed by the cruft-ng analysis tool. This is what the original proposal call "extrafiles": https://lists.debian.org/debian-policy/1998/04/msg00089.html I'm finally aiming for a version 1.00 of cruft-ng analysis software. Fixing all the packages of OpenStack at once with little effort would be awesome. So each /usr/share/cruft/rules/${PKPRM_TEMPLATE_PREFIX} would contains: /var/lib/${PKPRM_TEMPLATE_PREFIX}/ /var/log/${PKPRM_TEMPLATE_PREFIX}/ /var/lock is on a tmpfs an as such out of scope. Greetings Alexandre ------ https://sources.debian.org/src/cruft-ng/0.9.84/dh-cruft/dh_cruft if ($var_games) { push @purgelines, " if test -d \${DPKG_ROOT:-}/var/games/"; push @purgelines, " then"; push @purgelines, " rmdir --ignore-fail-on-non-empty \${DPKG_ROOT:-}/var/games/"; push @purgelines, " fi"; } autoscript($package, "postrm", "postrm-cruft", { 'PURGE' => join("\n", @purgelines)}); ------------- $ cat pkgos_postrm #!/bin/sh # -*- mode: shell-script -*- # Perform cleanups when removing a package # Prototype: pkgos_postrm <template-prefix-name> <package-name> $@ # Example: pkgos_postrm neutron neutron-common $@ pkgos_dbc_postrm () { local PKPRM_TEMPLATE_PREFIX PKPRM_PACKAGE_NAME PKPRM_TEMPLATE_PREFIX=${1} PKPRM_PACKAGE_NAME=${2} shift shift if [ -f /usr/share/debconf/confmodule ] ; then . /usr/share/debconf/confmodule # If the package has the template, then it means we're having a db, # and therefore we can call the dbconfig-common clean function. db_get ${PKPRM_TEMPLATE_PREFIX}/configure_db if [ "$RET" = "true" ] ; then if [ -f /usr/share/dbconfig-common/dpkg/postrm ] ; then . /usr/share/dbconfig-common/dpkg/postrm dbc_go ${PKPRM_PACKAGE_NAME} $@ else rm -f /etc/dbconfig-common/${PKPRM_PACKAGE_NAME}.conf if which ucf >/dev/null 2>&1; then ucf --purge /etc/dbconfig-common/${PKPRM_PACKAGE_NAME}.conf ucfr --purge ${PKPRM_PACKAGE_NAME} /etc/dbconfig-common/${PKPRM_PACKAGE_NAME}.conf fi fi fi fi rm -rf /var/lib/${PKPRM_TEMPLATE_PREFIX} /var/log/${PKPRM_TEMPLATE_PREFIX} /var/lock/${PKPRM_TEMPLATE_PREFIX} }

