bmuschko/gradle-nexus-plugin — pull request #25 by ept (2014-05-12 14:20:09+00:00)
Title: Better defaults for artifact signing

Thank you for gradle-nexus-plugin! It makes publishing to Sonatype OSS beautifully simple.

However, I'm not willing to put my GPG passphrase in a plaintext file, so I played around a bit with the signing configuration.

This patch doesn't change anything if the `signing.keyId`, `signing.secretKeyRingFile` and `signing.password` properties are configured, but it provides better defaults if they are not configured:

- If signing.keyId is missing, a more helpful error message is shown, explaining to the user how they can configure the property.
- If signing.secretKeyRingFile is missing, it defaults to the default location of GnuPG's secret keyring file on Unix-like systems.
- If signing.password is missing, it prompts the user. This avoids having to store your GPG passphrase in an unencrypted file on disk.

This is my first time attempting any custom Gradle build configuration, so my approach may be way off — if so, I'd love to see how to do this better :)

Also, sorry for lack of tests. gradle-nexus-plugin's integration tests fail for me (even before making any changes), so I wasn't sure where to start.