[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: cruft(-ng) and dh-cruft: handling and registering of dynamic files



Hi,

Le dim. 23 oct. 2022 à 04:24, Paul Wise <pabs@debian.org> a écrit :
> Thank you for your work on this, being able to register files generated
> at install time by maintainer scripts or even at runtime by system
> maintainence tools to particular packages is a very useful feature for
> keeping all the files on a system more easily managed.

The "cpigs" command has now a new "-C" command line switch
to output the ownership of all system files (static+volatile) in a single .csv.

I think this is something quite basic that can fill so many needs;
but simply did not existed before.

"apt-file" could be adapted to also transparently cache this information.
End-users of this tool would get better results without
having to change their habits.

    $ apt-file search /etc/subgid
    [nothing]
    $ cpigs -c | grep subgid
    /etc/subgid;base-passwd;f;1;19
    /etc/subgid-;base-passwd;f;1;0

The plan is to keep this .csv output stable,
whatever changes in the upstream dataflow:
which is now mix of dpkg&diversions + alternatives
+ custom fallback scripts that know and replicate how
UCF, logrotate, initramfs, grub, systemd, sysvinit
manage volatile files inside their postinst/postrm.

> I do worry about users removing files that they don't understand, based
> on feedback by cpigs/cruft-ng, but they do that already so... :)

I have seen some complaints about this online, and I agree...
original "cruft" tool looks more like an unfinished Q&A tool akin to piuparts
than an end-user tool for me.

> An ncdu or mc style interface (or plugins for those) to view cruft on a
> system sounds very useful in addition to the data export.

It's implemented but the ncdu datamodel does not allow
to insert the matched package name for the volatile files.

It's still nice to use if you need to quickly identify
where are the big volatile files piling up and take action.
Already done in real life.

Greetings


Reply to: