:: Re: [DNG] etckeeper: was: Er, Not …
Top Page
Delete this message
Reply to this message
Author: o1bigtenor
Date:  
To: Olaf Meeuwissen
CC: wirelessduck, Devuan ML
Subject: Re: [DNG] etckeeper: was: Er, Not that way ? .Re: Announcing Devuan 4.0: Chimaera!
On Thu, Oct 21, 2021 at 6:47 AM Olaf Meeuwissen via Dng <dng@???>
wrote:

> Hi wirelessduck,
>
> wirelessduck--- via Dng writes:
>
> >> On 20 Oct 2021, at 20:45, Olaf Meeuwissen via Dng <dng@???>
> wrote:
> >>
> >> I really looked into snapshotting but the etckeeper commit messages also
> >> list which packages changed, like so (after I "beautified" the logging a
> >> bit to suit my taste and needs)
> >>
> >> commit dd9602a525e590f24ec19904248938e6ab76e999 (HEAD -> master)
> >> Author: olaf <olaf@quark>
> >> Date: Mon Oct 11 21:48:25 2021 +0900
> >>
> >>      Committing changes in /etc after APT run

> >>
> >>      Package changes:
> >>      - debconf 1.5.71 all
> >>      + debconf 1.5.71+deb10u1 all
> >>      - libgssapi-krb5-2 1.17-3+deb10u2 amd64
> >>      + libgssapi-krb5-2 1.17-3+deb10u3 amd64
> >>      - libk5crypto3 1.17-3+deb10u2 amd64
> >>      + libk5crypto3 1.17-3+deb10u3 amd64
> >>      - libkrb5-3 1.17-3+deb10u2 amd64
> >>      + libkrb5-3 1.17-3+deb10u3 amd64
> >>      - libkrb5support0 1.17-3+deb10u2 amd64
> >>      + libkrb5support0 1.17-3+deb10u3 amd64
> >>      - libmariadb3 1:10.3.29-0+deb10u1 amd64
> >>      + libmariadb3 1:10.3.31-0+deb10u1 amd64

> >>
> >> which gives me a chance to pinpoint any culprits and submit bug reports
> >> if necessary with detailed info on the changed packages.
> >
> > Is this formatting configured in etckeeper or gitconfig? I would like
> > to try and replicate. It looks very useful.
>
> TL;DR: in etckeeper.
>
> The etckeeper utility does a good job of collecting the package changes
> out-of-the-box but the exact output is slightly different from what I
> included above. The out-of-the-box behaviour includes the output of
>
> diff -U0 $before $after | egrep '^[-+]'
>
> where $before and $after are "files" with the output of
>
>   dpkg-query -W -f '${Status}\t${Package} ${Version}\n' | \
>           egrep '(ok installed|ok config-files)' | cut -f2,3

>
> I've tweaked that a bit to insert a space after the '^[-+]' and run the
> diff output through `sort -k2` so I get the before and after package
> info closer together. I've also made a few very minor changes to start
> the message with a capital and capitalized APT.
>
> Without my changes, the above would have looked something like
>
> commit dd9602a525e590f24ec19904248938e6ab76e999 (HEAD -> master)
> Author: olaf <olaf@quark>
> Date: Mon Oct 11 21:48:25 2021 +0900
>
>       committing changes in /etc after apt run

>
>       Package changes:
>       -debconf 1.5.71 all
>       +debconf 1.5.71+deb10u1 all
>       -libgssapi-krb5-2 1.17-3+deb10u2 amd64
>       +libgssapi-krb5-2 1.17-3+deb10u3 amd64
>       -libk5crypto3 1.17-3+deb10u2 amd64
>       -libkrb5-3 1.17-3+deb10u2 amd64
>       -libkrb5support0 1.17-3+deb10u2 amd64
>       +libk5crypto3 1.17-3+deb10u3 amd64
>       +libkrb5-3 1.17-3+deb10u3 amd64
>       +libkrb5support0 1.17-3+deb10u3 amd64
>       -libmariadb3 1:10.3.29-0+deb10u1 amd64
>       +libmariadb3 1:10.3.31-0+deb10u1 amd64

>
> BTW, the version in chimaera (and later) also includes a section that
> lists the packages with configuration changes and includes the command
> line invocation that triggered the changes.
>
> Oh, I've also made a few changes to record package changes if nothing
> below /etc has changed.
>
> Hope this helps,
>


Mr Olaf
(and the rest of devuan land)

I found apt-cacher-ng to be a useful tool in tracking updates and in
minimizing my bandwidth.

Would apt-cacher-ng work with etckeeper?
Suggestions please.

TIA