lib/repo: Port gpg signing function to new code style
lib/repo: Port gpg signing function to new code style

We already had all of the autocleanups ready for this.

Closes: #1164
Approved by: jlebon

GNOME/ostree,GNOME/ostree,GNOME/ostree,GNOME/ostree,GNOME/ostree