projg2/getuto ? reverse-engineered prompt

Reverse engineered prompt

Build me a small shell tool called getuto for Gentoo that keeps the GPG keyring in /etc/portage/gnupg up to date for binary package verification.

If the keyring doesn’t exist yet, it should create it. If it already exists, it should refresh keys from keyservers or WKD and import newer keys when they’re available on the system. The goal is to make sure binary packages can be checked safely, including revocations and key renewals.

It should fit into the normal Portage flow so it runs before fetching binary packages when --getbinpkg or --getbinpkgonly is used. Also make it easy to disable with PORTAGE_TRUST_HELPER=true in /etc/portage/make.conf.

Keep it simple and reliable, with a clear main script and a basic test script if needed. If you need to confirm any current Gentoo or GPG behavior, look up the latest docs online and follow the usual conventions.

Are you gonna build this?

make sure you review the code using coderabbit

Try freeSponsored — opens CodeRabbit in a new tab