Sysop: | Amessyroom |
---|---|
Location: | Fayetteville, NC |
Users: | 28 |
Nodes: | 6 (1 / 5) |
Uptime: | 20:20:21 |
Calls: | 449 |
Files: | 1,045 |
Messages: | 99,070 |
Hi all,
I've been working for a while on pkgcraft[1] and related tooling that
could have the potential to run various CI checks server-side as a pre-receive git hook verifying commits. Previously, this wasn't at all possible due to portage/repoman and pkgcore/pkgcheck being too slow to feasibly run and give feedback within a second or two of interactively pushing.
[...]
From all this, my main questions to the dev community are the following:
- Do you see value in running a service that can reject commits due to
issues like invalid metadata during `git push`?
- Would the project be open to moving to a merge queue model?
- Are there others who would be interested in helping with the
development, testing, and maintenance of a git-hook service if that is
the chosen path?
On 11/25/24 12:15 PM, Tim Harder wrote:
From all this, my main questions to the dev community are the following:
- Do you see value in running a service that can reject commits due to
issues like invalid metadata during `git push`?
Yes please! This would be fantastic to have. Already, pushing is notI spent quite a bit of time fixing various QA issues (including tons of whitespace) reported by pkgcruft today, and the only thing better than
quite instantaneous since the hooks wait on e.g. pushing again to
mirrors, and I don't think waiting a couple seconds for significantly
greater peace of mind is at all a bad thing.
Would you be open to trialling this on GURU? It seems like a reasonable >target where it'd seriously reduce the amount of developer / trusted >contributor overhead when merging commits.
If so, what would that process look like, and how would we go about
getting the implementation started?
For anyone interested,
I've hacked up an initial, rough implementation of a pkgcruft-git
service that enables verifying ebuild commits during git's pre-receive
hook phase.
Currently it comes with a simple script that runs a local demo instance targeting the gentoo repo by default.
You can find the code and demo instructions in the pkgcruft-git crate directory of the pkgcraft repo [1].
If I can find the time, I'll try to write up a dev blog post about the service design in more detail as well as next steps if there is interest
in trying to use it in any official fashion in the future.
Thanks,
Tim
[1]: https://github.com/pkgcraft/pkgcraft/tree/main/crates/pkgcruft-git
It would be very nice to have it run over the PRs we are already
receiving on github...
For anyone interested,
I've hacked up an initial, rough implementation of a pkgcruft-git
service that enables verifying ebuild commits during git's pre-receive
hook phase.
Currently it comes with a simple script that runs a local demo instance targeting the gentoo repo by default.
You can find the code and demo instructions in the pkgcruft-git crate directory of the pkgcraft repo [1].
If I can find the time, I'll try to write up a dev blog post about the service design in more detail as well as next steps if there is interest
in trying to use it in any official fashion in the future.
Thanks,
Tim
[1]: https://github.com/pkgcraft/pkgcraft/tree/main/crates/pkgcruft-git
I've packaged this now as dev-vcs/pkgcruft-git (live-only for now). I'm
using the pre-push support you added (thank you!) locally with the
following in .git/hooks/pre-push:
pkgcruft-git-pre-push origin git+ssh://git@git.gentoo.org/repo/gentoo.git
and going from there. I encourage others to give it a go and share
feedback too.
If I can find the time, I'll try to write up a dev blog post about the
service design in more detail as well as next steps if there is interest
in trying to use it in any official fashion in the future.
Definitely. My hope is we can get this deployed on infra, but I think
it's going to be really valuable even without that locally.