On Wed, 7 Oct 2020 at 02:09, Shengjing Zhu <z...@debian.org> wrote: > Maybe due to the go-md2man v2 transition, docker.io is now FTBFS. > > dh_installman: warning: Section for > ./.gopath/src/github.com/docker/cli/man/man1/docker-attach.1 is computed as > "2020", which is not a valid section > dh_installman: error: Could not determine section for > ./.gopath/src/github.com/docker/cli/man/man1/docker-attach.1 > dh_installman: error: Aborting due to earlier error > make: *** [debian/rules:40: binary] Error 25
I did some digging, and I think this is actually due to a bug in https://github.com/spf13/cobra, specifically in https://github.com/spf13/cobra/blob/b97b5ead31f7d34f764ac8666e40c214bb8e06dc/doc/man_docs.go#L148. I believe "%% %s(%s)%s" there should actually be "%% %s %s %s" instead, so that it matches the syntax for ".TH" correctly (and this is what's causing "docker-attach.1" to start with ".TH DOCKER(1)Oct 2020" which is what makes "dh_installman" interpret it as section 2020 (".TH[space]program[space]section[space]..."). I think Someone™ should probably file an issue/PR with https://github.com/spf13/cobra explaining the issue. O:) ♥, - Tianon 4096R / B42F 6819 007F 00F8 8E36 4FD4 036A 9C25 BF35 7DD4