Commit Graph

4 Commits

Author SHA1 Message Date
Levente Polyak f386c13142
export-pkgbuild-keys: fix export for packages without validpgpkeys
In case the validpgpkeys array is empty or undefined, the empty printf
line only included a single line break which lead to mapfile -t
consuming it as an array with 1 element consisting of an empty string.

Fix this by only calling the printf in case the validpgpkeys array is
not empty. Without any output, the mapfile -t will simply produce an
empty array.

Signed-off-by: Levente Polyak <anthraxx@archlinux.org>
2022-06-22 00:51:22 +02:00
Levente Polyak 01b6196883
export-pkgbuild-keys: use TEMPDIR while exporting key
This avoids the possibility to pollute the keys directory with temporary
files if the script is aborted in between.

Signed-off-by: Levente Polyak <anthraxx@archlinux.org>
2022-06-09 21:10:03 +02:00
Levente Polyak 8d4c46d368
export-pkgbuild-keys: add simple success export messages
Signed-off-by: Levente Polyak <anthraxx@archlinux.org>
2022-06-09 21:06:38 +02:00
Allan McRae d00a28ea0e
Export source PGPs from PKGBUILD on commit
Provide a tool to export keys listed in the PKGBUILDs validpgpkeys to
keys/pgp/$fingerprint.asc.

The presense of the "keys" directory alongside the PKGBUILD in trunk/
is tested during commitpkg.  If the directory is abscent, keys are
exported and added to the commit.  If the directory is present, a
check is made to ensure all valid PGP keys are provided.

Signed-off-by: Allan McRae <allan@archlinux.org>
Signed-off-by: Levente Polyak <anthraxx@archlinux.org>
2022-06-09 20:41:18 +02:00