Gradle init task does not set extension for non-jar dependencies

I used “gradle init” to import a Maven project and it largely worked, except that it did not set the ‘ext’ for configured dependencies. This caused the build to fail, as apparently the Maven resolver tries multiple extensions automatically, while Gradle tries only “jar”.