buildscript { repositories { mavenLocal() mavenCentral() maven { url "https://plugins.gradle.org/m2/" } } dependencies { classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" classpath "org.jetbrains.kotlin:kotlin-serialization:$kotlin_version" classpath "com.github.breadmoirai:github-release:$github_release_plugin_version" } } plugins { id "org.jetbrains.kotlin.multiplatform" version "$kotlin_version" apply false id "org.jetbrains.kotlin.plugin.serialization" version "$kotlin_version" apply false } // temporal crutch until legacy tests will be stabled or legacy target will be removed allprojects { if (it != rootProject.findProject("docs")) { tasks.whenTaskAdded { task -> if(task.name == "jsLegacyBrowserTest" || task.name == "jsLegacyNodeTest") { task.enabled = false } } } } private String getCurrentVersionChangelog() { OutputStream changelogDataOS = new ByteArrayOutputStream() exec { standardOutput = changelogDataOS commandLine './changelog_info_retriever', "$library_version", 'CHANGELOG.md' } return changelogDataOS.toString().trim() } if (new File(projectDir, "secret.gradle").exists()) { apply from: './secret.gradle' apply plugin: "com.github.breadmoirai.github-release" githubRelease { token "${project.property('GITHUB_RELEASE_TOKEN')}" owner "InsanusMokrassar" repo "TelegramBotAPI" tagName "$library_version" releaseName "$library_version" targetCommitish "$library_version" body getCurrentVersionChangelog() } }