Plugin Publish plugin ignores ~/.gradle/ if the project has a file

The documentation on the plugin portal states that gradle.publish.key and gradle.publish.secret should be configured in ~/.gradle/ However, it doesn’t appear to work:

Execution failed for task ':publishPlugins'.
> Missing publishing keys. Please set gradle.publish.key and gradle.publish.secret system properties or login using the login task.

I’ve verified that the properties are configured correctly by outputting them from the build script:

println project.getProperty('gradle.publish.key')
println project.getProperty('gradle.publish.secret')

Strangely, if I remove my project’s file, it works as expected and uses the properties configured in ~/.gradle/

1 Like

Hi Andy

This looks like a bug. The workaround is to either set the properties in the local or set them as system properties. I’ll raise a JIRA issue.



1 Like

Raised GRADLE-3281

1 Like