Switch from maintainer comments to maintainer field
As of not too long ago, abuild
officially supports setting maintainer via a field in an APKBUILD instead of a comment, e.g. maintainer="Newbyte <newbyte@postmarketos.org>
instead of # Maintainer: Newbyte <newbyte@postmarketos.org>
: https://gitlab.alpinelinux.org/alpine/abuild/-/issues/10147
There is still some discussion about whether to deprecate the comment format however: https://gitlab.alpinelinux.org/alpine/tsc/-/issues/88
However, personally, I think that the maintainer field is superior for the reasons outlined in the first issue I linked and that we should switch pmbootstrap to using it too.
There are four parts of the code that I've identified which would need to be adapted for this:
-
https://gitlab.postmarketos.org/postmarketOS/pmbootstrap/-/blob/afecbb151dea132a6ec51593c0137b4d14b59cc1/pmb/data/tests/APKBUILD.qemu-amd64#L2-3
- This one also presents the question of what we want to do with our "Co-Maintainer" comments. Personally, I'm inclined to keep these as comments since they don't affect the resulting package.
-
https://gitlab.postmarketos.org/postmarketOS/pmbootstrap/-/blob/afecbb151dea132a6ec51593c0137b4d14b59cc1/pmb/aportgen/__init__.py#L91
- This should probably still look for the "Maintainer"-comment since we may want to operate on APKBUILDs that use the comment-format even if we switch over.
-
https://gitlab.postmarketos.org/postmarketOS/pmbootstrap/-/blob/afecbb151dea132a6ec51593c0137b4d14b59cc1/pmb/parse/_apkbuild.py#L415-454
-
_parse_comment_tags()
probably can stay as-is, butmaintainers()
needs to change.
-
-
https://gitlab.postmarketos.org/postmarketOS/pmbootstrap/-/blob/afecbb151dea132a6ec51593c0137b4d14b59cc1/pmb/aportgen/core.py#L110-112
- Self-explanatory I think.
Edited by Newbyte