diff --git a/ballerina/build.gradle b/ballerina/build.gradle index 550bc83..27f3675 100644 --- a/ballerina/build.gradle +++ b/ballerina/build.gradle @@ -17,19 +17,8 @@ import org.apache.tools.ant.taskdefs.condition.Os -buildscript { - repositories { - maven { - url = 'https://maven.pkg.github.com/ballerina-platform/plugin-gradle' - credentials { - username System.getenv("packageUser") - password System.getenv("packagePAT") - } - } - } - dependencies { - classpath "io.ballerina:plugin-gradle:${project.ballerinaGradlePluginVersion}" - } +plugins { + id 'io.ballerina.plugin' } description = 'Ballerina - Math Vector Ballerina Generator' @@ -54,8 +43,6 @@ def stripBallerinaExtensionVersion(String extVersion) { } } -apply plugin: 'io.ballerina.plugin' - ballerina { packageOrganization = packageOrg module = packageName diff --git a/build.gradle b/build.gradle index a4d20bc..dacc5e7 100644 --- a/build.gradle +++ b/build.gradle @@ -16,10 +16,10 @@ */ plugins { - id "com.github.spotbugs" version "${githubSpotbugsVersion}" - id "com.github.johnrengelman.shadow" version "${githubJohnrengelmanShadowVersion}" - id "de.undercouch.download" version "${underCouchDownloadVersion}" - id "net.researchgate.release" version "${researchgateReleaseVersion}" + id "com.github.spotbugs" + id "com.github.johnrengelman.shadow" + id "de.undercouch.download" + id "net.researchgate.release" } allprojects { @@ -58,6 +58,21 @@ allprojects { } } +subprojects { + + configurations { + ballerinaStdLibs + jbalTools + } + + dependencies { + /* JBallerina Tools */ + jbalTools ("org.ballerinalang:jballerina-tools:${ballerinaLangVersion}") { + transitive = false + } + } +} + def moduleVersion = project.version.replace("-SNAPSHOT", "") release { diff --git a/gradle.properties b/gradle.properties index 56c2929..cd82a0d 100644 --- a/gradle.properties +++ b/gradle.properties @@ -4,10 +4,10 @@ version=1.1.0-SNAPSHOT ballerinaLangVersion=2201.11.0-20250127-101700-a4b67fe5 -ballerinaGradlePluginVersion=2.0.1 +ballerinaGradlePluginVersion=2.3.0 testngVersion=7.6.1 slf4jVersion=1.7.30 -githubSpotbugsVersion=6.0.18 -githubJohnrengelmanShadowVersion=8.1.1 -underCouchDownloadVersion=5.4.0 -researchgateReleaseVersion=2.8.0 +spotbugsPluginVersion=6.0.18 +shadowJarPluginVersion=8.1.1 +downloadPluginVersion=5.4.0 +releasePluginVersion=2.8.0 diff --git a/settings.gradle b/settings.gradle index c7db013..7c35da2 100644 --- a/settings.gradle +++ b/settings.gradle @@ -7,6 +7,27 @@ * in the user manual at https://docs.gradle.org/6.3/userguide/multi_project_builds.html */ +pluginManagement { + plugins { + id "com.github.spotbugs" version "${spotbugsPluginVersion}" + id "com.github.johnrengelman.shadow" version "${shadowJarPluginVersion}" + id "de.undercouch.download" version "${downloadPluginVersion}" + id "net.researchgate.release" version "${releasePluginVersion}" + id "io.ballerina.plugin" version "${ballerinaGradlePluginVersion}" + } + + repositories { + gradlePluginPortal() + maven { + url = 'https://maven.pkg.github.com/ballerina-platform/*' + credentials { + username System.getenv("packageUser") + password System.getenv("packagePAT") + } + } + } +} + plugins { id "com.gradle.enterprise" version "3.2" }