Gradle Plugin Development Plugin VCL URL not accepting SSH URLs

Seems like an oversight. SSH URLs are valid URLs. Using:

gradlePlugin {
    vcsUrl = "git@github.com:org/repo.git"
}

fails with:

Execution failed for task ':plugin:publishPlugins'.
Can't parse URL 'git@github.com:org/repo.git'

Plugins that only use the SSH protocol for VCS can not be published as the Gradle plugin expects a HTTP URL.

That is actually not an URL.
It is an SCP-like syntax that the Git client accepts, but not a valid URL.
A valid SSH URL would be ssh://git@github.com/org/repo.git.
As this is used in the POM in an URL field, you should probably use the proper URL syntax.

1 Like