Re: golang-github-theupdateframework-go-tuf TUFv0+TUFv2 to unstable
On Thu, 12 Dec 2024 at 03:27, Simon Josefsson <simon@josefsson.org> wrote:
> If someone understands how to write a debian/watch file that tracks the
> two independent orig.tar components (see debian/README.source), and/or
> how to get gbp-export-orig to re-create the orig.tar as two separate
> components, that would be a nice improvement. But it is feasible to
> manage this manually.
I'm not sure why the resulting tarballs I get from this don't match
your uploaded tarballs, but the contents do appear correct (perhaps
doing diffoscope on them would be prudent):
version=4
opts="filenamemangle=s%(?:.*?)?v?(\d[\d.]*)\.tar\.gz%@PACKAGE@-$1.tar.gz%,\
dversionmangle=s/[+].*$//,\
uversionmangle=s/(\d)[_\.\-\+]?(RC|rc|pre|dev|beta|alpha)[.]?(\d*)$/$1~$2$3/"
\
https://github.com/theupdateframework/go-tuf/tags .*/v?(\d\S*)\.tar\.gz debian
opts="component=v0,\
filenamemangle=s%(?:.*?)?v?(\d[\d.]*)\.tar\.gz%@PACKAGE@-$1.tar.gz%,\
dversionmangle=s/^.*[+]//,\
uversionmangle=s/(\d)[_\.\-\+]?(RC|rc|pre|dev|beta|alpha)[.]?(\d*)$/$1~$2$3/"
\
https://github.com/theupdateframework/go-tuf/tags .*/v?(\d\S*)\.tar\.gz debian
Or as a diff, if you prefer (the key bit is "dversionmangle" and then
adding "component=" but swapping the dversionmangle regex):
diff --git a/debian/watch b/debian/watch
index f842468..c1c55e0 100644
--- a/debian/watch
+++ b/debian/watch
@@ -1,4 +1,11 @@
version=4
opts="filenamemangle=s%(?:.*?)?v?(\d[\d.]*)\.tar\.gz%@PACKAGE@-$1.tar.gz%,\
+ dversionmangle=s/[+].*$//,\
+ uversionmangle=s/(\d)[_\.\-\+]?(RC|rc|pre|dev|beta|alpha)[.]?(\d*)$/$1~$2$3/"
\
+ https://github.com/theupdateframework/go-tuf/tags
.*/v?(\d\S*)\.tar\.gz debian
+
+opts="component=v0,\
+ filenamemangle=s%(?:.*?)?v?(\d[\d.]*)\.tar\.gz%@PACKAGE@-$1.tar.gz%,\
+ dversionmangle=s/^.*[+]//,\
uversionmangle=s/(\d)[_\.\-\+]?(RC|rc|pre|dev|beta|alpha)[.]?(\d*)$/$1~$2$3/"
\
https://github.com/theupdateframework/go-tuf/tags
.*/v?(\d\S*)\.tar\.gz debian
♥,
- Tianon
4096R / B42F 6819 007F 00F8 8E36 4FD4 036A 9C25 BF35 7DD4
Reply to: