scala.cli.commands.publish.checks.PgpSecretKeyCheck
See thePgpSecretKeyCheck companion object
final case class PgpSecretKeyCheck(options: PublishSetupOptions, coursierCache: FileCache[Task], configDb: () => ConfigDb, logger: Logger, backend: SttpBackend[Identity, Any]) extends OptionCheck
Checks if:
- keys for signing files are present in using directives (either PGP or GPG)
- public key is uploaded to specified keyservers (if keys present are PGP)
If any of the above fails then try the following to find missing keys:
- if secretKey using directive is already present then fill any missing from CLI options
- if secretKey is specified in options use only keys from options
- if --random-secret-key is specified and it's CI use new generated keys
- default to keys in config if this fails throw
After previous step figures out which values should be used in setup do:
- if it's CI then upload github secrets and write using directives as 'using ci.key env:GITHUB_SECRET_VAR'
- otherwise write down the key values to publish.conf file in the same form as they were passed to options, if the values come from config don't write them to file
Finally upload the public key to the keyservers that are specified
Attributes
- Companion
- object
- Graph
-
- Supertypes
-
trait Serializabletrait Producttrait Equalstrait OptionCheckclass Objecttrait Matchableclass Any
Members list
In this article