Note: Instead of using this command a keyring should be placed directly in the /etc/apt/trusted.gpg.d/ directory
with a descriptive name and either "gpg" or "asc" as file extension.\
— apt-key(8) manpage
Here's a couple reasons why apt-key add might be deprecated. I would suggest using something like this:
I've noticed that a couple lines above you the script mentions that gpg can't be used because it “always creates files on disk”, but that shouldn't be a problem because gpg --dearmor doesn't touch disk at all. We could instead write ASCII-armoured key, but this doesn't work on some systems.
Would there be any other concerns? I'll be happy to send in a PR!
Here's a couple reasons why
apt-key add
might be deprecated. I would suggest using something like this:I've noticed that a couple lines above you the script mentions that
gpg
can't be used because it “always creates files on disk”, but that shouldn't be a problem becausegpg --dearmor
doesn't touch disk at all. We could instead write ASCII-armoured key, but this doesn't work on some systems.Would there be any other concerns? I'll be happy to send in a PR!