Hello Otto, My way of working is very manual and possibly too labour intensive...
On Thu, Oct 24, 2024 at 09:36:04PM +0100, Otto Kekäläinen wrote: > Hi, > > I occasionally run into the situation that a package has been NMU'd or > otherwise updated directly into the Debian repositories, > bypassing/ignoring that a packaging git repository existed. I was > wondering what techniques other DDs use to > 1) detect that the git packaging repository was bypassed/diverged? apt-cache policy $pkgname (probably better to do rmadison or something if you don't have all repos in your sources.list) and compare to head debian/changelog of the source I'm about to modify. > 2) bring the git repository back in sync with minimal effort? 1/ Look if there are any open merge requests on the salsa repo. 2/ Look at the close bug reports in the NMU and see if split up patch series has been posted there. 3/ import the NMU as a single commit. (Ofcourse for both 1 & 2 it's also needed to verify the diff actually matches what was uploaded, which happens more often then you would think is not the case.) > > So far, I have settled on having the deb-src for Debian sid configured > on my laptop (even though it is not running sid) and then inside the > git packaging checkout directory run for example: > > gbp import-dsc --verbose --pristine-tar apt:j4-dmenu-desktop/sid > > This will both check if there are any newer uploads than what git > knows about, and if needed, also download, apply and commit the > uploads using the uploader as the git author. The result of this > particular example is visible in > https://salsa.debian.org/otto/j4-dmenu-desktop/-/commit/62ea4cd6df973138e3a452b09250510da5279db4 > > I wanted to check if anyone knows any better techniques or mechanisms > than trying to remember to run this command manually before working on > a package? I would very much prefer if it was possible in Debian to not allow the archive to get out of sync with packaging git repo (for example when it lives under salsa.debian.org/debian which uploaders should have access to already). That would probably also require some "tag to upload" solution to be implemented first I presume. > > - Otto > Regards, Andreas Henriksson