Because of reasons, the machine I'm developing on, is not connected to the internet.
I have a local copy of all dependencies for the app and the build script. I want to run Gradle with Kotlin scripts, and specifically, the kotlin-dsl gradle plugin. For some reason, just downloading the dependencies, is not enough.
I currently have:
<dependency>
<groupId>org.gradle.kotlin.kotlin-dsl</groupId>
<artifactId>org.gradle.kotlin.kotlin-dsl.gradle.plugin</artifactId>
<version>1.4.9</version>
<type>pom</type>
</dependency>
<dependency>
<groupId>org.gradle.kotlin</groupId>
<artifactId>gradle-kotlin-dsl-plugins</artifactId>
<version>1.4.9</version>
</dependency>
<dependency>
<groupId>org.jetbrains.kotlin</groupId>
<artifactId>kotlin-compiler-embeddable</artifactId>
<version>1.4.20</version>
</dependency>
<dependency>
<groupId>org.jetbrains.kotlin</groupId>
<artifactId>kotlin-stdlib-jdk8</artifactId>
<version>1.4.20</version>
</dependency>
<dependency>
<groupId>org.jetbrains.kotlin</groupId>
<artifactId>kotlin-sam-with-receiver</artifactId>
<version>1.4.20</version>
</dependency>
<dependency>
<groupId>org.jetbrains.kotlin</groupId>
<artifactId>kotlin-gradle-plugin</artifactId>
<version>1.4.20</version>
</dependency>
<dependency>
<groupId>org.jetbrains.kotlin</groupId>
<artifactId>kotlin-scripting-compiler-embeddable</artifactId>
<version>1.4.20</version>
</dependency>
(don't ask why that's in Maven format, but it should get the message across)
But in offline runtime, running any Gradle task fails with
FAILURE: Build failed with an exception.
* Where:
Build file '<path>/build.gradle.kts' line: 1
* What went wrong:
Plugin [id: 'org.gradle.kotlin.kotlin-dsl', version: '1.4.9'] was not found in any of the following sources:
- Gradle Core Plugins (plugin is not in 'org.gradle' namespace)
- Plugin Repositories (could not resolve plugin artifact 'org.gradle.kotlin.kotlin-dsl:org.gradle.kotlin.kotlin-dsl.gradle.plugin:1.4.9')
Searched in the following repositories:
Gradle Central Plugin Repository
So, if anyone knows which other dependencies I need, or where to look to find out, that would be greatly appreciated.