Skip to content

Commit dd3e728

Browse files
p7novEkaterina.Volodko
andauthored
update: remove Bintray/JCenter from EAP instruction (JetBrains#2079)
* update: remove Bintray from EAP instruction * fix: fixed coroutines version in code blocks; formatting corrections Co-authored-by: Ekaterina.Volodko <ekaterina.volodko@jetbrains.com>
1 parent c768457 commit dd3e728

File tree

1 file changed

+21
-100
lines changed

1 file changed

+21
-100
lines changed

docs/topics/configure-build-for-eap.md

Lines changed: 21 additions & 100 deletions
Original file line numberDiff line numberDiff line change
@@ -6,8 +6,7 @@ You only need to configure your build manually for existing projects — project
66

77
To configure your build to use the EAP version of Kotlin, you need to:
88

9-
* Specify the EAP version of Kotlin. Available EAP versions are listed [here](eap.md#build-details).
10-
* Add the EAP repository to the build – <https://dl.bintray.com/kotlin/kotlin-eap>.
9+
* Specify the EAP version of Kotlin. Available EAP versions are listed [here](eap.md#build-details).
1110
* Change the versions of dependencies to EAP ones.
1211
The EAP version of Kotlin may not work with the libraries of the previously released version.
1312

@@ -20,114 +19,44 @@ The following procedures describe how to configure your build in Gradle and Mave
2019

2120
This section describes how you can:
2221

23-
* [Adjust the Kotlin version and add the EAP repository](#adjust-the-kotlin-version-and-add-the-eap-repository)
22+
* [Adjust the Kotlin version](#adjust-the-kotlin-version)
2423
* [Adjust versions in dependencies](#adjust-versions-in-dependencies)
2524

26-
### Adjust the Kotlin version and add the EAP repository
25+
### Adjust the Kotlin version
2726

28-
Depending on your configuration approach, you need to perform different steps in your build files.
29-
This section describes common options, but if you use a different approach, you can refer to [Gradle documentation](https://docs.gradle.org/) for assistance.
30-
31-
This section covers:
32-
33-
* [Option 1. Configure in the build and settings files](#option-1-configure-in-the-build-and-settings-files)
34-
* [Option 2. Configure in the build file only](#option-2-configure-in-the-build-file-only)
35-
36-
#### Option 1. Configure in the build and settings files
27+
In the `plugins` block within `build.gradle(.kts)`, change the `KOTLIN-EAP-VERSION` to the actual EAP version,
28+
such as `%kotlinEapVersion%`. Available EAP versions are listed [here](eap.md#build-details).
3729

38-
1. In the `plugins` block within `build.gradle` (`build.gradle.kts`), change the `KOTLIN-EAP-VERSION` to the actual EAP version, such as `%kotlinEapVersion%`. Available EAP versions are listed [here](eap.md#build-details).
39-
40-
Alternatively, you can specify the EAP version in the `pluginManagement` block in `settings.gradle` (`settings.gradle.kts`) – see [Gradle documentation](https://docs.gradle.org/current/userguide/plugins.html#sec:plugin_version_management) for details.
41-
2. In the `repositories` block, specify the EAP repository – <https://dl.bintray.com/kotlin/kotlin-eap> – for dependencies.
30+
Alternatively, you can specify the EAP version in the `pluginManagement` block in `settings.gradle(.kts)` – see [Gradle documentation](https://docs.gradle.org/current/userguide/plugins.html#sec:plugin_version_management) for details.
4231

4332
Here is an example for the Multiplatform project.
4433

4534
<tabs>
4635

4736
```groovy
4837
plugins {
49-
id 'java'
50-
id 'org.jetbrains.kotlin.multiplatform' version 'KOTLIN-EAP-VERSION'
38+
id 'java'
39+
id 'org.jetbrains.kotlin.multiplatform' version 'KOTLIN-EAP-VERSION'
5140
}
5241
5342
repositories {
54-
mavenCentral()
55-
maven { url 'https://dl.bintray.com/kotlin/kotlin-eap' }
56-
maven { url 'https://kotlin.bintray.com/kotlinx' }
43+
mavenCentral()
5744
}
5845
```
5946

6047
```kotlin
6148
plugins {
62-
java
63-
kotlin("multiplatform") version "KOTLIN-EAP-VERSION"
64-
}
65-
repositories {
66-
mavenCentral()
67-
maven ("https://dl.bintray.com/kotlin/kotlin-eap")
68-
maven ("https://kotlin.bintray.com/kotlinx")
69-
}
70-
```
71-
72-
</tabs>
73-
74-
* In the `pluginManagement` block within `settings.gradle` (`settings.gradle.kts`), specify the EAP repository – <https://dl.bintray.com/kotlin/kotlin-eap>.
75-
76-
<tabs>
77-
78-
```groovy
79-
pluginManagement {
80-
repositories {
81-
mavenCentral()
82-
gradlePluginPortal()
83-
maven { url 'https://dl.bintray.com/kotlin/kotlin-eap' }
84-
}
49+
java
50+
kotlin("multiplatform") version "KOTLIN-EAP-VERSION"
8551
}
86-
```
8752

88-
```kotlin
89-
pluginManagement {
90-
repositories {
91-
mavenCentral()
92-
gradlePluginPortal()
93-
maven ("https://dl.bintray.com/kotlin/kotlin-eap")
94-
}
53+
repositories {
54+
mavenCentral()
9555
}
9656
```
9757

9858
</tabs>
9959

100-
#### Option 2. Configure in the build file only
101-
102-
1. In `build.gradle` (`build.gradle.kts`), change the `KOTLIN-EAP-VERSION` in the `buildscript` block to the actual EAP version,
103-
such as `%kotlinEapVersion%`. Available EAP versions are listed [here](eap.md#build-details).
104-
2. Add the EAP repository – <https://dl.bintray.com/kotlin/kotlin-eap> – to the `buildscript` block.
105-
3. In the `repositories` block, specify the EAP repository for dependencies.
106-
107-
```groovy
108-
buildscript {
109-
repositories {
110-
mavenCentral()
111-
gradlePluginPortal()
112-
maven { url "https://dl.bintray.com/kotlin/kotlin-eap" }
113-
}
114-
115-
dependencies {
116-
classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:KOTLIN-EAP-VERSION"
117-
}
118-
}
119-
120-
apply plugin: "kotlin"
121-
122-
repositories {
123-
maven { url "https://dl.bintray.com/kotlin/kotlin-eap" }
124-
}
125-
126-
dependencies {
127-
compile "org.jetbrains.kotlin:kotlin-stdlib"
128-
}
129-
```
130-
13160
### Adjust versions in dependencies
13261

13362
If you use kotlinx libraries in your project, your versions of the libraries may not be compatible with the EAP version of Kotlin.
@@ -149,13 +78,13 @@ For the **kotlinx.coroutines** library, add the version number – `%coroutinesE
14978

15079
```groovy
15180
dependencies {
152-
implementation "org.jetbrains.kotlinx:kotlinx-coroutines-core:1.3.5-1.4-M1"
81+
implementation "org.jetbrains.kotlinx:kotlinx-coroutines-core:%coroutinesEapVersion%"
15382
}
15483
```
15584

15685
```kotlin
15786
dependencies {
158-
implementation("org.jetbrains.kotlinx:kotlinx-coroutines-core:1.3.5-1.4-M1")
87+
implementation("org.jetbrains.kotlinx:kotlinx-coroutines-core:%coroutinesEapVersion%")
15988
}
16089
```
16190

@@ -174,24 +103,16 @@ Available EAP versions are listed [here](eap.md#build-details).
174103

175104
<repositories>
176105
<repository>
177-
<id>bintray.kotlin.eap</id>
178-
<name>Bintray Kotlin EAP Repository</name>
179-
<url>https://dl.bintray.com/kotlin/kotlin-eap</url>
106+
<id>mavenCentral</id>
107+
<url>https://repo1.maven.org/maven2/</url>
180108
</repository>
181109
</repositories>
182110

183111
<pluginRepositories>
184-
<pluginRepository>
185-
<releases>
186-
<enabled>true</enabled>
187-
</releases>
188-
<snapshots>
189-
<enabled>false</enabled>
190-
</snapshots>
191-
<id>bintray.kotlin.eap</id>
192-
<name>Bintray Kotlin EAP Repository</name>
193-
<url>https://dl.bintray.com/kotlin/kotlin-eap</url>
194-
</pluginRepository>
112+
<pluginRepository>
113+
<id>mavenCentral</id>
114+
<url>https://repo1.maven.org/maven2/</url>
115+
</pluginRepository>
195116
</pluginRepositories>
196117

197118
<dependencies>

0 commit comments

Comments
 (0)