Hi Nicolas, On Sat, Nov 18, 2023 at 06:27:42PM +0100, Nicolas Boulenguez wrote: > Have you seen this? > https://lists.debian.org/debian-devel/2023/08/
What exactly are you referring to? That's the whole month's archive :) Yes I do read d-devel so I've likely seen whatever you're pointing to :p > > I've been toying with the idea of setting up a Debian-wide system to nag > > maintainers about out-of-date, inconsistent or plain broken packaging git > > repos. This logic to diff the dsc against one built from unstable could be > > part of that effort. > > Some will probably argue that you are trying to influence their > priorities, that non-git .dsc formats are obsolete, and so on. And that's a bad thing because ... ? There's a huge difference between nudging and forcing :) > Moreover, even if you guess the git tag and whether patches are > applied, there is probably no deterministic way to tell if .gitignore > matches the workflow of upstream, Debian or both. Sounds like a job for a new config option in debian/source/ or similar, this is conceptually no different than lintian false-positives. As long as there's a way to override I don't see a problem. > For the avoidance of doubt, I would appreciate such alerts, a Debian > policy about tags and patches, and that .gitignore is only allowed for > self defense... I for sure don't have all this thought yet, I'm happy to collaborate on designing this system if you're interested. BTW: are you at ccc congress? > > Even with git what may be missing is a hook in dpkg-buildpackage to abort > > the (source) build when the worktree is unclean, > > I often build with manual changes in debian/ that I want tested before > committed. Right yeah same. So that wouldn't really help. gbp's --git-ignore-new is already annoying me enough :) > The script I am using is too lazy for public exposure. You can always send me those shameful scripts directly, I don't judge.sh. > Here are the parts unrelated with pbuilder. > > # After a successful build, clean and compare the source directory > # with the contents extracted by dpkg-source. > # The diff must match debian/clean.diff if it exists, else be empty. > # Example: > # Only in ../dsc: Makefile.in > # Only in ../dsc: config.h > # Only in ../dsc: configure > # If lots of files are removed, repackaging with Files-Excluded is > # probably a better option, see uscan(1). > > #!/bin/sh > set -Ceux > > source=$(dpkg-parsechangelog -SSource) > version=$(dpkg-parsechangelog -SVersion) > dsc_dir=../dsc > > debian/rules clean > dpkg-source -x ../$source_$version.dsc $dsc_dir > if ! (diff -qr $dsc_dir . || true) | diff -N debian/clean.diff -; then > # Display a full diagnostic while $dsc_dir is available. > diff -ru $dsc_dir . || true > # When -ru is empty, -N above already reported the obsolete clean.diff. > fi > rm -fr $dsc_dir I see, this is actually really clever. I don't see why we couldn't do this diff on the buildds to get reporting for this Debian wide. I've been meaning to give sbuild some love anyhow. --Daniel
signature.asc
Description: PGP signature